These utilities core dumped if given no arguments.

This commit is contained in:
Marty Kraimer
1996-07-29 20:29:00 +00:00
parent dc6972ba06
commit 1947538968
3 changed files with 15 additions and 0 deletions

View File

@@ -45,6 +45,13 @@ int main(int argc,char **argv)
static char *subSep = ",";
/*Look for options*/
if(argc<2) {
fprintf(stderr,
"usage: dbExpand -Idir -Idir "
"-S substitutions -S substitutions"
" file1.dbd file2.dbd ...\n");
exit(0);
}
while((strncmp(argv[1],"-I",2)==0)||(strncmp(argv[1],"-S",2)==0)) {
if(strncmp(argv[1],"-I",2)==0) {
pstr = &path;

View File

@@ -49,6 +49,10 @@ int main(int argc,char **argv)
static char *subSep = ",";
/*Look for options*/
if(argc<2) {
fprintf(stderr,"usage: dbToMenu -Idir -Idir file.dbd\n");
exit(0);
}
while((strncmp(argv[1],"-I",2)==0)||(strncmp(argv[1],"-S",2)==0)) {
if(strncmp(argv[1],"-I",2)==0) {
pstr = &path;

View File

@@ -52,6 +52,10 @@ int main(int argc,char **argv)
static char *subSep = ",";
/*Look for options*/
if(argc<2) {
fprintf(stderr,"usage: dbToRecordtypeH -Idir -Idir file.dbd\n");
exit(0);
}
while((strncmp(argv[1],"-I",2)==0)||(strncmp(argv[1],"-S",2)==0)) {
if(strncmp(argv[1],"-I",2)==0) {
pstr = &path;