summaryrefslogtreecommitdiff
path: root/src/librc-depend.c
diff options
context:
space:
mode:
authorRoy Marples <roy@marples.name>2007-04-06 01:04:07 +0000
committerRoy Marples <roy@marples.name>2007-04-06 01:04:07 +0000
commit657be653400bdb9fc8ab13037e51ecfbc1af9d40 (patch)
tree8e876d2a345eb56dff9b7c732a082bc00720d020 /src/librc-depend.c
parent308042c87bd920d787265f1854bf1695bdbab8e4 (diff)
downloadopenrc-657be653400bdb9fc8ab13037e51ecfbc1af9d40.tar.gz
openrc-657be653400bdb9fc8ab13037e51ecfbc1af9d40.tar.bz2
openrc-657be653400bdb9fc8ab13037e51ecfbc1af9d40.tar.xz
Misc fixes, plugged a memory leak in runscript.c and use va_copy to avoid nasty segfaults
Diffstat (limited to 'src/librc-depend.c')
-rw-r--r--src/librc-depend.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/librc-depend.c b/src/librc-depend.c
index 707b954..e39287b 100644
--- a/src/librc-depend.c
+++ b/src/librc-depend.c
@@ -630,7 +630,7 @@ int rc_update_deptree (bool force)
setenv ("RC_LIBDIR", RC_LIBDIR, 0);
/* Phase 1 */
- if ((fp = popen (GENDEP, "r")) == NULL)
+ if (! (fp = popen (GENDEP, "r")))
eerrorx ("popen: %s", strerror (errno));
deptree = rc_xmalloc (sizeof (rc_depinfo_t));
@@ -809,7 +809,7 @@ int rc_update_deptree (bool force)
This works and should be entirely shell parseable provided that depend
names don't have any non shell variable characters in
*/
- if ((fp = fopen (RC_DEPTREE, "w")) == NULL)
+ if (! (fp = fopen (RC_DEPTREE, "w")))
eerror ("fopen `%s': %s", RC_DEPTREE, strerror (errno));
else
{