projects
/
irspy-moved-to-github.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge branch 'master' of ssh://git.indexdata.com/home/git/pub/irspy
[irspy-moved-to-github.git]
/
bin
/
setrlimit.c
diff --git
a/bin/setrlimit.c
b/bin/setrlimit.c
index
0efa41a
..
9097dac
100644
(file)
--- a/
bin/setrlimit.c
+++ b/
bin/setrlimit.c
@@
-1,5
+1,3
@@
-/* $Id: setrlimit.c,v 1.3 2007-08-14 10:17:11 mike Exp $ */
-
/*
* A simple wrapper program for the setrlimit(2) system call, which
* can be used to run a subprocess under a different regime -- much
/*
* A simple wrapper program for the setrlimit(2) system call, which
* can be used to run a subprocess under a different regime -- much
@@
-99,13
+97,13
@@
int main(int argc, char **argv) {
new.rlim_max = n;
if (verbose) {
if (new.rlim_cur != old.rlim_cur)
new.rlim_max = n;
if (verbose) {
if (new.rlim_cur != old.rlim_cur)
- printf("%s: changing soft %s from %ld to %ld\n",
- argv[0], types[i].name,
- (long) old.rlim_cur, (long) new.rlim_cur);
+ fprintf(stderr, "%s: changing soft %s from %ld to %ld\n",
+ argv[0], types[i].name,
+ (long) old.rlim_cur, (long) new.rlim_cur);
if (new.rlim_max != old.rlim_max)
if (new.rlim_max != old.rlim_max)
- printf("%s: changing hard %s from %ld to %ld\n",
- argv[0], types[i].name,
- (long) old.rlim_max, (long) new.rlim_max);
+ fprintf(stderr, "%s: changing hard %s from %ld to %ld\n",
+ argv[0], types[i].name,
+ (long) old.rlim_max, (long) new.rlim_max);
}
if (setrlimit(types[i].value, &new) < 0) {
fprintf(stderr, "%s: setrlimit(%s=%ld): %s\n",
}
if (setrlimit(types[i].value, &new) < 0) {
fprintf(stderr, "%s: setrlimit(%s=%ld): %s\n",
@@
-130,8
+128,8
@@
int main(int argc, char **argv) {
}
if (verbose)
}
if (verbose)
- printf("%s: user='%s', optind=%d, new argc=%d, argv[0]='%s'\n",
- argv[0], user, optind, argc-optind, argv[optind]);
+ fprintf(stderr, "%s: user='%s', optind=%d, new argc=%d, argv[0]='%s'\n",
+ argv[0], user, optind, argc-optind, argv[optind]);
execvp(argv[optind], argv+optind);
fprintf(stderr, "%s: execvp('%s'): %s\n",
execvp(argv[optind], argv+optind);
fprintf(stderr, "%s: execvp('%s'): %s\n",