|
|
| version 1.11, 2025/04/02 03:02:42 | version 1.13, 2025/04/10 01:24:39 |
|---|---|
| Line 24 | Line 24 |
| * along with FreeM. If not, see <https://www.gnu.org/licenses/>. | * along with FreeM. If not, see <https://www.gnu.org/licenses/>. |
| * | * |
| * $Log$ | * $Log$ |
| * Revision 1.13 2025/04/10 01:24:39 snw | |
| * Remove C++ style comments | |
| * | |
| * Revision 1.12 2025/04/09 19:52:02 snw | |
| * Eliminate as many warnings as possible while building with -Wall | |
| * | |
| * Revision 1.11 2025/04/02 03:02:42 snw | * Revision 1.11 2025/04/02 03:02:42 snw |
| * Stop requiring users to pass -e to fmadm when -u or -g are passed | * Stop requiring users to pass -e to fmadm when -u or -g are passed |
| * | * |
| Line 904 set0: | Line 910 set0: |
| if (isalpha (vn[0]) && *(codptr + 1) == ':') { | if (isalpha (vn[0]) && *(codptr + 1) == ':') { |
| char sc_string[255]; | char sc_string[255]; |
| register int sci; | |
| codptr += 2; | codptr += 2; |
| expr (NAME); | expr (NAME); |
| Line 941 set0: | Line 946 set0: |
| if (*++codptr != '=') { | if (*++codptr != '=') { |
| /* SET A++ or SET A-- equivalent to SET A+=1 SET A-=1 currently disabled */ | /* unary ++/-- */ |
| //#ifdef NEVER | |
| if ((ch == '+' || ch == '-') && ch == *codptr) { | if ((ch == '+' || ch == '-') && ch == *codptr) { |
| codptr++; | codptr++; |
| setop = ch; | setop = ch; |
| Line 951 set0: | Line 955 set0: |
| goto set2; | goto set2; |
| } | } |
| //#endif /* NEVER */ | |
| merr_raise (ASSIGNER); | merr_raise (ASSIGNER); |
| break; | break; |
| Line 1037 set2: | Line 1040 set2: |
| if (new_and_set == TRUE) new_and_set = FALSE; | if (new_and_set == TRUE) new_and_set = FALSE; |
| if (new_object == TRUE) new_object = FALSE; | if (new_object == TRUE) new_object = FALSE; |
| /* | |
| set1: | set1: |
| */ | |
| if (*codptr != ',') break; | if (*codptr != ',') break; |
| if (*++codptr == '@') goto again; | if (*++codptr == '@') goto again; |
| Line 1601 set10: | Line 1606 set10: |
| } | } |
| if (stcat (tmp2, &tmp3[arg4]) == 0) { | if (stcat (tmp2, &tmp3[arg4]) == 0) { |
| merr_raise (M56); //JPW | merr_raise (M56); /* snw */ |
| goto err; | goto err; |
| } | } |
| Line 2380 s_end: | Line 2385 s_end: |
| #ifdef DEBUG_NEWSTACK | #ifdef DEBUG_NEWSTACK |
| printf ("EXTRINSIC\r\n"); | printf ("EXTRINSIC\r\n"); |
| #endif | #endif |
| //printf (" extr_types[%d] = '%d'\r\n", nstx, extr_types[nstx]); | |
| if (*codptr == EOL || *codptr == SP) { | if (*codptr == EOL || *codptr == SP) { |
| #ifdef DEBUG_NEWSTACK | #ifdef DEBUG_NEWSTACK |
| Line 4005 off3: | Line 4009 off3: |
| goto set2; | goto set2; |
| } | } |
| /* | |
| post_new: | post_new: |
| */ | |
| ch = nstx; | ch = nstx; |
| while (nestc[ch] == FOR) ch--; /* FOR does not define a NEW level */ | while (nestc[ch] == FOR) ch--; /* FOR does not define a NEW level */ |
| Line 5095 open_socket: | Line 5100 open_socket: |
| #endif | #endif |
| if (nestc[nstx] == BREAK) { | if (nestc[nstx] == BREAK) { |
| // printf ("nestc[nstx] was BREAK\r\n"); | |
| if (repQUIT) continue; | if (repQUIT) continue; |
| merr_raise (OK - CTRLB); | merr_raise (OK - CTRLB); |
| goto zgo; /*cont. single step */ | goto zgo; /*cont. single step */ |
| } | } |
| // else { | |
| // printf ("nestc[nstx] was _not_ BREAK\r\n"); | |
| // } | |
| if (nestc[nstx] == FOR) { | if (nestc[nstx] == FOR) { |
| Line 5679 zgo: | Line 5680 zgo: |
| } | } |
| case ZWRITE: | case ZWRITE: |
| zwrite: | |
| { | { |
| short k; | short k; |
| char w_tmp[512]; | char w_tmp[512]; |
| Line 5805 zwritep: | Line 5803 zwritep: |
| expr (NAME); | expr (NAME); |
| //if (varnam[0] == '^') merr_raise (GLOBER); | |
| if (merr () > OK) goto err; | if (merr () > OK) goto err; |
| codptr++; | codptr++; |
| Line 6586 evthandler: /* for event hand | Line 6583 evthandler: /* for event hand |
| /* run the next iteration of GTK's event loop */ | /* run the next iteration of GTK's event loop */ |
| //TODO: replace with libXt event loop | /* TODO: replace with libXt event loop */ |
| //gtk_main_iteration_do (TRUE); | /* gtk_main_iteration_do (TRUE); */ |
| /* dequeue any events */ | /* dequeue any events */ |
| evt_count = mwapi_dequeue_events (syn_handlers); | evt_count = mwapi_dequeue_events (syn_handlers); |
| if (evt_count) { | if (evt_count) { |
| /* write them out */ | /* write them out */ |
| //printf ("event handlers = '%s'\r\n", syn_handlers); | /* printf ("event handlers = '%s'\r\n", syn_handlers); */ |
| syn_event_entry_nstx = nstx; | syn_event_entry_nstx = nstx; |
| Line 7039 restart: | Line 7036 restart: |
| DSW &= ~BIT0; /* enable ECHO */ | DSW &= ~BIT0; /* enable ECHO */ |
| // print here | /* print here */ |
| { | { |
| char *t_rtn; | char *t_rtn; |
| char *t_nsn = (char *) malloc (STRLEN * sizeof (char)); | char *t_nsn = (char *) malloc (STRLEN * sizeof (char)); |
| Line 7377 direct_mode: | Line 7374 direct_mode: |
| #endif | #endif |
| if (merr () > OK) goto err; | if (merr () > OK) goto err; |
| // printf ("zbflag = %d\r\n", zbflag); | |
| if (code[0] == EOL && zbflag && nestc[nstx] == BREAK) { | if (code[0] == EOL && zbflag && nestc[nstx] == BREAK) { |
| //printf ("cont single step\r\n"); | |
| debug_mode = TRUE; | debug_mode = TRUE; |
| merr_raise (OK - CTRLB); | merr_raise (OK - CTRLB); |
| //printf ("ierr now '%d'\r\n", ierr); | |
| goto zgo; | goto zgo; |
| } /* single step */ | } /* single step */ |
| } | } |
| Line 7453 void rbuf_dump(void) | Line 7445 void rbuf_dump(void) |
| for (i = 0; i < NO_OF_RBUF; i++) { | for (i = 0; i < NO_OF_RBUF; i++) { |
| sprintf (flgs, ""); | flgs[0] = '\0'; |
| if (ages[i] == 0) { | if (ages[i] == 0) { |
| sprintf (rnam, "---------"); | sprintf (rnam, "---------"); |