summaryrefslogtreecommitdiff
path: root/lib/rpmts.h
diff options
context:
space:
mode:
authorPanu Matilainen <pmatilai@redhat.com>2008-05-08 11:53:42 +0300
committerPanu Matilainen <pmatilai@redhat.com>2008-05-08 11:53:42 +0300
commit6ca5373aa1f58ccc60e844bd8fd006a738670883 (patch)
treee247734973c366663ec1561713a3f6f2d461bd38 /lib/rpmts.h
parent6006265faf97316d9685b0dc958770f50b954a3e (diff)
downloadrpm-6ca5373aa1f58ccc60e844bd8fd006a738670883.tar.gz
rpm-6ca5373aa1f58ccc60e844bd8fd006a738670883.tar.bz2
rpm-6ca5373aa1f58ccc60e844bd8fd006a738670883.zip
Check for transaction root sanity in rpmtsSetRootDir()
- only regular paths starting with / permitted - change prototype to permit return codes
Diffstat (limited to 'lib/rpmts.h')
-rw-r--r--lib/rpmts.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/rpmts.h b/lib/rpmts.h
index 5d8928aa0..0b4af3693 100644
--- a/lib/rpmts.h
+++ b/lib/rpmts.h
@@ -416,11 +416,11 @@ const char * rpmtsRootDir(rpmts ts);
/** \ingroup rpmts
* Set transaction rootDir, i.e. path to chroot(2).
- * @todo disallow funky http:// etc urls...
* @param ts transaction set
* @param rootDir new transaction rootDir (or NULL)
+ * @return 0 on success, -1 on error (invalid rootDir)
*/
-void rpmtsSetRootDir(rpmts ts, const char * rootDir);
+int rpmtsSetRootDir(rpmts ts, const char * rootDir);
/** \ingroup rpmts
* Get transaction currDir, i.e. current directory before chroot(2).