@@ -109,7 +109,7 @@ static int do_child(int lockfd, int i, int to_lockers, int from_lockers)
static int
usage(char *argv0)
{
- errx(1, "Usage: %s [-i iterations] [-n nr_children] <filename>", argv0);
+ errx(1, "Usage: %s [-n nr_procs] [-l nr_loops] <filename>", argv0);
}
int main(int argc, char *argv[])
@@ -126,9 +126,9 @@ int main(int argc, char *argv[])
total.tv_sec = 0;
total.tv_nsec = 0;
- while ((opt = getopt(argc, argv, "i:n:")) != -1) {
+ while ((opt = getopt(argc, argv, "l:n:")) != -1) {
switch (opt) {
- case 'i':
+ case 'l':
iter = atoi(optarg);
break;
case 'n':
@@ -158,7 +158,7 @@ static int do_child(int fd, int id, int nproc, int to_lockers, int from_lockers)
static int
usage(char *argv0)
{
- errx(1, "Usage: %s [-i iterations] [-n nr_children] [-s] <filename>", argv0);
+ errx(1, "Usage: %s [-n nr_procs] [-l nr_loops] [-s] <filename>", argv0);
}
int main(int argc, char *argv[])
@@ -175,9 +175,9 @@ int main(int argc, char *argv[])
total.tv_sec = 0;
total.tv_nsec = 0;
- while ((opt = getopt(argc, argv, "i:n:s")) != -1) {
+ while ((opt = getopt(argc, argv, "l:n:s")) != -1) {
switch (opt) {
- case 'i':
+ case 'l':
iter = atoi(optarg);
break;
case 'n':