On Wed, Aug 09, 2017 at 12:10:22AM +0200, Jakub Wilk wrote:
> Package: e2fsprogs
> Version: 1.43.5-1
> 
> $ gzip -d underwrite.ext2.gz
> $ valgrind /sbin/e2fsck -f -y underwrite.ext2 > /dev/null
> ==6645== Memcheck, a memory error detector
> ==6645== Copyright (C) 2002-2017, and GNU GPL'd, by Julian Seward et al.
> ==6645== Using Valgrind-3.13.0 and LibVEX; rerun with -h for copyright info
> ==6645== Command: /sbin/e2fsck -f -y underwrite.ext2
> ==6645==
> e2fsck 1.43.5 (04-Aug-2017)
> ==6645== Invalid write of size 1
> ==6645==    at 0x48349C0: memset (in 
> /usr/lib/valgrind/vgpreload_memcheck-x86-linux.so)
> ==6645==    by 0x4892A2E: memset (string3.h:90)
> ==6645==    by 0x4892A2E: raw_read_blk (unix_io.c:250)
> ==6645==    by 0x48936FE: unix_read_blk64.part.5 (unix_io.c:862)
> ==6645==    by 0x4880D82: ext2fs_read_inode_full (inode.c:803)
> ==6645==    by 0x4880FF4: ext2fs_read_inode (inode.c:845)
> ==6645==    by 0x11745F: check_resize_inode (super.c:346)
> ==6645==    by 0x1126C0: main (unix.c:1761)
> ==6645==  Address 0x4affac7 is 1 bytes before a block of size 1,024 alloc'd
> ==6645==    at 0x482E2BC: malloc (in 
> /usr/lib/valgrind/vgpreload_memcheck-x86-linux.so)
> ==6645==    by 0x488198D: ext2fs_get_mem (ext2fs.h:1740)
> ==6645==    by 0x488198D: io_channel_alloc_buf (io_manager.c:140)
> ==6645==    by 0x4892CDE: alloc_cache (unix_io.c:401)
> ==6645==    by 0x4893CEE: unix_open_channel (unix_io.c:644)
> ==6645==    by 0x4885046: ext2fs_open2 (openfs.c:160)
> ==6645==    by 0x1151AA: try_open_fs (unix.c:1141)
> ==6645==    by 0x1120E3: main (unix.c:1447)
> ...

I'm not able to reproduce the problem.  Can you double check whether
you uploaded the correct image?  (In particular, is it possible that
you uploaded the image after it was modified by running "/sbin/e2fsck
-f -y" on the image?

Thanks,

                                                - Ted

<tytso@callcc> {/build/e2fsprogs-maint/e2fsck}  
1279% gunzip < /tmp/underwrite.ext2.gz  > /tmp/underwrite.ext2
<tytso@callcc> {/build/e2fsprogs-maint/e2fsck}  
1280% sha1sum /tmp/underwrite.ext2
32f671c8659cd0ac2f2d273b45669642d016344a  /tmp/underwrite.ext2
<tytso@callcc> {/build/e2fsprogs-maint/e2fsck}  
1281% valgrind /sbin/e2fsck -f -y /tmp/foo.img > /dev/null
==7619== Memcheck, a memory error detector
==7619== Copyright (C) 2002-2017, and GNU GPL'd, by Julian Seward et al.
==7619== Using Valgrind-3.13.0 and LibVEX; rerun with -h for copyright info
==7619== Command: /sbin/e2fsck -f -y /tmp/foo.img
==7619== 
e2fsck 1.43.5 (04-Aug-2017)
==7619== 
==7619== HEAP SUMMARY:
==7619==     in use at exit: 18,231 bytes in 163 blocks
==7619==   total heap usage: 480 allocs, 317 frees, 184,872 bytes allocated
==7619== 
==7619== LEAK SUMMARY:
==7619==    definitely lost: 0 bytes in 0 blocks
==7619==    indirectly lost: 0 bytes in 0 blocks
==7619==      possibly lost: 0 bytes in 0 blocks
==7619==    still reachable: 18,231 bytes in 163 blocks
==7619==         suppressed: 0 bytes in 0 blocks
==7619== Rerun with --leak-check=full to see details of leaked memory
==7619== 
==7619== For counts of detected and suppressed errors, rerun with: -v
==7619== ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 0 from 0)

Reply via email to