Guest User

ext2fsd: fix Ext2Mgr hang at startup

a guest
Dec 4th, 2017
372
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. ext2fsd: Fix Ext2Mgr hang at startup.
  2. Partial revert of git commits d8632a1 and d570f95
  3.  
  4.  Ext3Fsd/memory.c | 12 ++++++++----
  5.  1 file changed, 8 insertions(+), 4 deletions(-)
  6.  
  7. diff --git a/Ext3Fsd/memory.c b/Ext3Fsd/memory.c
  8. index f8f333e..68d5edb 100644
  9. --- a/Ext3Fsd/memory.c
  10. +++ b/Ext3Fsd/memory.c
  11. @@ -2428,7 +2428,15 @@ Ext2InitializeVcb( IN PEXT2_IRP_CONTEXT IrpContext,
  12.          /* initialize UUID and serial number */
  13.          if (Ext2IsNullUuid(sb->s_uuid)) {
  14.              ExUuidCreate((UUID *)sb->s_uuid);
  15. +        } else {
  16. +            /* query parameters from registry */
  17. +            if (!NT_SUCCESS(Ext2PerformRegistryVolumeParams(Vcb))) {
  18. +                /* don't mount this volume */
  19. +                Status = STATUS_UNRECOGNIZED_VOLUME;
  20. +                __leave;
  21. +            }
  22.          }
  23. +
  24.          Vpb->SerialNumber = ((ULONG*)sb->s_uuid)[0] +
  25.                              ((ULONG*)sb->s_uuid)[1] +
  26.                              ((ULONG*)sb->s_uuid)[2] +
  27. @@ -2713,10 +2721,6 @@ Ext2InitializeVcb( IN PEXT2_IRP_CONTEXT IrpContext,
  28.  
  29.          /* get anything doen, then refer target device */
  30.          ObReferenceObject(Vcb->TargetDeviceObject);
  31. -
  32. -        /* query parameters from registry */
  33. -        Ext2PerformRegistryVolumeParams(Vcb);
  34. -
  35.          SetLongFlag(Vcb->Flags, VCB_INITIALIZED);
  36.  
  37.      } __finally {
RAW Paste Data

Adblocker detected! Please consider disabling it...

We've detected AdBlock Plus or some other adblocking software preventing Pastebin.com from fully loading.

We don't have any obnoxious sound, or popup ads, we actively block these annoying types of ads!

Please add Pastebin.com to your ad blocker whitelist or disable your adblocking software.

×