#773944 ntfs-3g: ntfsfix fails with invalid pointer error in free()

Package:
ntfs-3g
Source:
ntfs-3g
Description:
read/write NTFS driver for FUSE
Submitter:
Gary Dale
Date:
2014-12-29 18:18:05 UTC
Severity:
normal
#773944#5
Date:
2014-12-26 04:22:19 UTC
From:
To:
Dear Maintainer,

*** Reporter, please consider answering these questions, where appropriate ***

   * What led up to the situation?
I was testing the file system on a usb hard drive partioned with ntfs

   * What exactly did you do (or not do) that was effective (or ineffective)?
ntfsfix /dev/sdk1
I also ran smartctl -t long /dev/sdk && smartctl -H /dev/sdk. The disk passed.

   * What was the outcome of this action?
I get two sets of sync/fsync errors followed by the invalid pointer error.

   * What outcome did you expect instead?
I was expecting the program to scan the entire disk and at least report any errors that
it found.


*** End of the template - remove these template lines ***

#773944#10
Date:
2014-12-26 16:04:14 UTC
From:
To:
The full output from the command is:

root@transponder:/home/garydale# ntfsfix /dev/sdk1
Mounting volume... OK
Processing of $MFT and $MFTMirr completed successfully.
Checking the alternate boot sector... OK
NTFS volume version is 3.1.
NTFS partition /dev/sdk1 was processed successfully.
Failed to sync device /dev/sdk1: Input/output error
Failed to fsync device /dev/sdk1: Input/output error
Failed to sync device /dev/sdk1: Input/output error
Failed to fsync device /dev/sdk1: Input/output error
*** Error in `ntfsfix': free(): invalid pointer: 0x00007f733989b678 ***
Aborted

#773944#15
Date:
2014-12-29 18:15:06 UTC
From:
To:
 > *** Error in `ntfsfix': free(): invalid pointer: 0x00007f733989b678 ***

This is caused by retrying a failed umount before leaving
ntfsfix, and the attached patch should fix this bug.

The failed umount is a consequence of not being able to
write to /dev/sdk1, and IMHO this is caused by some
hardware error. As ntfsfix finds no error, you should be
able to mount the device read-only.