nice.c (9b50d9027575220cb6dd09b3e62f03f511e908b8) nice.c (54e66fcad5eae44880f740926ada45607ffaeef6)
1/*
2 * Copyright (c) 1989, 1993, 1994
3 * The Regents of the University of California. All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

--- 50 unchanged lines hidden (view full) ---

59
60int
61main(argc, argv)
62 int argc;
63 char *argv[];
64{
65 int niceness = DEFNICE;
66
1/*
2 * Copyright (c) 1989, 1993, 1994
3 * The Regents of the University of California. All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

--- 50 unchanged lines hidden (view full) ---

59
60int
61main(argc, argv)
62 int argc;
63 char *argv[];
64{
65 int niceness = DEFNICE;
66
67 if (argc < 2)
68 errx(1, "usage: nice [-number] command [arguments]");
67 if (argv[1][0] == '-')
68 if (argv[1][1] == '-' || isdigit(argv[1][1])) {
69 niceness = atoi(argv[1] + 1);
70 ++argv;
71 } else
72 errx(1, "illegal option -- %s", argv[1]);
73
74 if (argv[1] == NULL)

--- 19 unchanged lines hidden ---
69 if (argv[1][0] == '-')
70 if (argv[1][1] == '-' || isdigit(argv[1][1])) {
71 niceness = atoi(argv[1] + 1);
72 ++argv;
73 } else
74 errx(1, "illegal option -- %s", argv[1]);
75
76 if (argv[1] == NULL)

--- 19 unchanged lines hidden ---