cgsecurity / testdisk

TestDisk & PhotoRec
https://www.cgsecurity.org/
GNU General Public License v2.0
1.58k stars 195 forks source link

Confusion between .h and .sh #19

Closed AtlasHackert closed 7 years ago

AtlasHackert commented 7 years ago

TestDisk sometimes gets confused between .h and .sh files. I have a shell file, starting with: #! /bin/sh

However, it also contains the line: for f in /etc/apache2/sites-enabled/* \

which causes file_txt.c line 1302-1303 to mark it as ".h" instead. I would expect the shell-header to take precedence...

cgsecurity commented 7 years ago

I think this problem is already solved. Can you check with latest 7.1-WIP or latest source code ?

AtlasHackert commented 7 years ago

Sorry for the slow response, I had to set-up some stuff to test this. And you're right: 7.0 (which I was using) gets it wrong, but the current 7.1-WIP works perfectly!