path: root/pseudo_util.c
diff options
authorPeter Seebach <peter.seebach@windriver.com>2011-02-08 15:17:21 -0600
committerPeter Seebach <peter.seebach@windriver.com>2011-02-08 15:21:57 -0600
commit1d5f26a775ed856e0397af4660f8f1ad48d1dd09 (patch)
tree10dc00709cc74f69c538e368394c49eda3cba393 /pseudo_util.c
parent5434325fc887817ebb2bad36313d8277992cef1d (diff)
Expand paths on exec.
This is fussy, because we have to actually do the path search ourselves as best we can to handle unqualified paths. The result, though, is more meaningful logs. Along the way, fix some bitrot in the comments in pseudo_fix_path and friends.
Diffstat (limited to 'pseudo_util.c')
1 files changed, 2 insertions, 4 deletions
diff --git a/pseudo_util.c b/pseudo_util.c
index dc55b0c..704655e 100644
--- a/pseudo_util.c
+++ b/pseudo_util.c
@@ -590,11 +590,9 @@ pseudo_fix_path(const char *base, const char *path, size_t rootlen, size_t basel
*current = '\0';
/* at any given point:
* current points to just after the last / of newpath
- * path points to the next path element of path
+ * path points to the next element of path
* newpathlen is the total allocated length of newpath
- * (current - newpathlen) is the used length of newpath
- * oldpath is the starting point of path
- * (path - oldpath) is how far into path we are
+ * (current - newpath) is the used length of newpath
if (pseudo_append_elements(&newpath, &effective_root, &newpathlen, &current, path, pathlen, leave_last) != -1) {