Archived
1
0
Fork 0

Make the other modules use error.c

This commit is contained in:
Henrik Hautakoski 2011-08-04 11:10:08 +02:00
parent 6bc3ffde5d
commit a2f2e58353
7 changed files with 26 additions and 32 deletions

View file

@ -22,8 +22,9 @@
#include <string.h>
#include "cconf.h"
#include "env.h"
#include "error.h"
static char *usage = "dlight-read-config [ <file> | -h ]\n";
static char *usagestr = "dlight-read-config [ <file> | -h ]";
int main(int argc, char **argv) {
@ -33,8 +34,7 @@ int main(int argc, char **argv) {
if (argc > 1) {
if (!strcmp(argv[1], "-h")) {
fprintf(stderr, usage);
return 1;
usage(usagestr);
}
strncpy(file, argv[1], sizeof(file));
} else {