diff options
author | Roy Marples <roy@marples.name> | 2008-03-21 08:31:04 +0000 |
---|---|---|
committer | Roy Marples <roy@marples.name> | 2008-03-21 08:31:04 +0000 |
commit | e505e6ea4131224d4f11e87d8b086c9e35b448a2 (patch) | |
tree | ef1da263af27526c8482f6af7b20297d7df4bd7b | |
parent | e47661449a7fe3c52ff0b5766bfa54699e1030bd (diff) |
We should only free the buffer when done reading the dir.
-rw-r--r-- | src/librc/librc-daemon.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/librc/librc-daemon.c b/src/librc/librc-daemon.c index 46162d51..d553b876 100644 --- a/src/librc/librc-daemon.c +++ b/src/librc/librc-daemon.c @@ -553,7 +553,6 @@ bool rc_service_daemons_crashed(const char *service) break; } } - free(line); fclose(fp); pid = 0; @@ -621,6 +620,7 @@ bool rc_service_daemons_crashed(const char *service) break; } closedir(dp); + free(line); return retval; } |