]> granicus.if.org Git - psmisc/commitdiff
Merge branch 'fix/pslog_unterminated_string' into 'master'
authorCraig Small <csmall@enc.com.au>
Sun, 1 May 2016 05:36:22 +0000 (05:36 +0000)
committerCraig Small <csmall@enc.com.au>
Sun, 1 May 2016 05:36:22 +0000 (05:36 +0000)
pslog: fix unterminated string and memory leaks

Adding null terminator to buf string.

Cleaned a memory leak  calling closedir on /proc/$PID/fd,  that was left open.

`==29483==
==29483== HEAP SUMMARY:
==29483==     in use at exit: 0 bytes in 0 blocks
==29483==   total heap usage: 256 allocs, 256 frees, 70,990 bytes allocated
==29483==
==29483== All heap blocks were freed -- no leaks are possible
==29483==
==29483== ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 0 from 0)
==29483== ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 0 from 0)`

See merge request !2


Trivial merge