git-svn-id: svn://svn.oetiker.ch/rrdtool/branches/1.2/program@672
a5681a0c-68f1-0310-ab6d-
d61299d08faa
gettimeofday(&starttime,&tz);
#endif
RemoteMode=1;
gettimeofday(&starttime,&tz);
#endif
RemoteMode=1;
if ((argc == 3) && strcmp("",argv[2])){
if (getuid()==0){
if ((argc == 3) && strcmp("",argv[2])){
if (getuid()==0){
chroot(argv[2]);
if (errno!=0){
fprintf(stderr,"ERROR: can't change root to '%s' errno=%d\n",
chroot(argv[2]);
if (errno!=0){
fprintf(stderr,"ERROR: can't change root to '%s' errno=%d\n",
}
ChangeRoot=1;
firstdir="/";
}
ChangeRoot=1;
firstdir="/";
+#else
+ fprintf(stderr,"ERROR: change root is not supported by your OS "
+ "or at least by this copy of rrdtool\n");
+ exit(1);
+#endif
+ } else {
-#else
- fprintf(stderr,"ERROR: change root is not supported by your OS "
- "or at least by this copy of rrdtool\n");
- exit(1);
-#endif
while (fgets(aLine, sizeof(aLine)-1, stdin)){
if ((argc = CountArgs(aLine)) == 0) {
while (fgets(aLine, sizeof(aLine)-1, stdin)){
if ((argc = CountArgs(aLine)) == 0) {