* link/z80/lkmain.c (afile): allow periods in directory names
[fw/sdcc] / as / mcs51 / lkmain.c
index fd11cf39458126d69138259fdfa24751dfd407be..06d26aa582eb499b52e434b989a117523816c1c8 100644 (file)
@@ -800,6 +800,8 @@ parse()
        char fid[NINPUT];
 
        while ((c = getnb()) != 0) {
+               if ( c == ';')
+                       return(0);
                if ( c == '-') {
                        while (ctype[c=get()] & LETTER) {
                                switch(c) {
@@ -923,6 +925,8 @@ parse()
                                        lkexit(1);
                                }
                        }
+                       if ( c == ';')
+                               return(0);
                } else
                if (ctype[c] & ILL) {
                        fprintf(stderr, "Invalid input");
@@ -1228,8 +1232,11 @@ char *ft;
        }
 
        /*Add the extension*/
-       strcat(fb, ".");
-       strcat(fb, strlen(ft)?ft:"rel");
+       if (fb[i] != '.')
+       {
+               strcat(fb, ".");
+               strcat(fb, strlen(ft)?ft:"rel");
+       }
        
        fp = fopen(fb, omode);
        if (fp==NULL)