Mercurial > pkg
annotate src/hg-wrapper.c @ 19:4fbe69d24a9c
major consolidation.
author | Robert McIntyre <rlm@mit.edu> |
---|---|
date | Wed, 09 Jan 2013 12:32:58 +0000 |
parents | cd47c42f1d0a |
children | c75924bd38e3 |
rev | line source |
---|---|
rlm@12 | 1 #include <pipeline.h> |
rlm@13 | 2 #include <unistd.h> |
rlm@12 | 3 |
rlm@12 | 4 main( int argc, char ** argv){ |
rlm@12 | 5 pipecmd* p = pipecmd_new("hg"); |
rlm@13 | 6 |
rlm@12 | 7 int i; |
rlm@12 | 8 for(i = 1; i < argc; i++){ |
rlm@12 | 9 pipecmd_arg(p, argv[i]); |
rlm@12 | 10 } |
rlm@12 | 11 |
rlm@13 | 12 setreuid(geteuid(), geteuid()); |
rlm@13 | 13 setregid(getegid(), getegid()); |
rlm@13 | 14 |
rlm@12 | 15 pipecmd_exec(p); |
rlm@12 | 16 } |