/[baselayout]/trunk/src/rc.c
Gentoo

Diff of /trunk/src/rc.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

Revision 2834 Revision 2835
170 } else if (strcmp (applet, "esyslog") == 0 || 170 } else if (strcmp (applet, "esyslog") == 0 ||
171 strcmp (applet, "elog") == 0) { 171 strcmp (applet, "elog") == 0) {
172 char *dot = strchr (argv[0], '.'); 172 char *dot = strchr (argv[0], '.');
173 if ((level = syslog_decode (dot + 1, prioritynames)) == -1) 173 if ((level = syslog_decode (dot + 1, prioritynames)) == -1)
174 eerrorx ("%s: invalid log level `%s'", applet, argv[0]); 174 eerrorx ("%s: invalid log level `%s'", applet, argv[0]);
175
176 if (argc < 3)
177 eerrorx ("%s: not enough arguments", applet);
178
179 unsetenv ("RC_ELOG");
180 setenv ("RC_ELOG", argv[1], 1);
181
175 argc--; 182 argc -= 2;
176 argv++; 183 argv += 2;
177 }
178 } 184 }
179 185 }
180 186
181 if (argc > 0) { 187 if (argc > 0) {
182 for (i = 0; i < argc; i++) 188 for (i = 0; i < argc; i++)
183 l += strlen (argv[i]) + 1; 189 l += strlen (argv[i]) + 1;
184 190

Legend:
Removed from v.2834  
changed lines
  Added in v.2835

  ViewVC Help
Powered by ViewVC 1.1.20