The problem is in: char command[128]; sprintf(command, "first part of command %s second part of command", filename.c_str());
The string is larger than 128 bytes. But valgrind does not detect this? Am I missing something? I forgot to mention, I'm using valgrind from SVN in an ARM machine. I usually use the version from SVN since it has a lot of false positives corrected. The log file shows 0 errors but a lot of: ==2346== Warning: invalid file descriptor 29541 in syscall read() which make it difficult to interpret the results. Should I report a bug and a suggestion upon this SVN version? On 01/01/2015 10:19 PM, "João M. S. Silva" wrote: > Let me correct myself: gdb catches the change on fd, but I thought it > didn't because it didn't break the execution. It just got running 100% > CPU and when I pressed ctrl-c it stopped in the culprit line. It always > stopped on the same line which was strange but I didn't realize it was > the line where the fd got erroneously modified. > > Now I ran it step by step with display of the variable and got it. -- João M. S. Silva ------------------------------------------------------------------------------ Dive into the World of Parallel Programming! The Go Parallel Website, sponsored by Intel and developed in partnership with Slashdot Media, is your hub for all things parallel software development, from weekly thought leadership blogs to news, videos, case studies, tutorials and more. Take a look and join the conversation now. http://goparallel.sourceforge.net _______________________________________________ Valgrind-users mailing list Valgrind-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/valgrind-users