annotate rvinterf/tmsh/usercmd.c @ 985:8109185528c1

tfc139: new logic actually works
author Mychaela Falconia <falcon@ivan.Harhan.ORG>
date Sat, 12 Dec 2015 03:24:52 +0000
parents 1ee80bcb0fd0
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
182
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
1 /*
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
2 * This module implements fc-tmsh user command dispatch.
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
3 */
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
4
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
5 #include <sys/types.h>
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
6 #include <ctype.h>
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
7 #include <stdio.h>
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
8 #include <string.h>
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
9 #include <strings.h>
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
10 #include <stdlib.h>
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
11
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
12 extern char usercmd[];
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
13
198
c9ea2f7441a5 fc-tmsh: abb[rw] commands implemented
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 192
diff changeset
14 extern void cmd_abbr();
c9ea2f7441a5 fc-tmsh: abb[rw] commands implemented
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 192
diff changeset
15 extern void cmd_abbw();
257
c413e791595a fc-tmsh: added check-ffs1 command, getting ready to begin ffs2 implementation
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 198
diff changeset
16 extern void cmd_check_ffs1();
189
a95d253ef952 fc-tmsh: some basic tmcore commands implemented
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 182
diff changeset
17 extern void cmd_dieid();
182
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
18 extern void cmd_etmpkt();
258
ab66a2eea6a8 fc-tmsh: beginning of ffs2 command dispatch
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 257
diff changeset
19 extern void cmd_ffs2();
978
1ee80bcb0fd0 fc-tmsh: omr (old-style memory read) command implemented
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents: 267
diff changeset
20 extern void cmd_omr();
189
a95d253ef952 fc-tmsh: some basic tmcore commands implemented
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 182
diff changeset
21 extern void cmd_ping();
a95d253ef952 fc-tmsh: some basic tmcore commands implemented
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 182
diff changeset
22 extern void cmd_r8();
a95d253ef952 fc-tmsh: some basic tmcore commands implemented
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 182
diff changeset
23 extern void cmd_r16();
a95d253ef952 fc-tmsh: some basic tmcore commands implemented
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 182
diff changeset
24 extern void cmd_r32();
263
b5b54feb111a fc-tmsh: set-imeisv command implemented
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 260
diff changeset
25 extern void cmd_set_imeisv();
264
0c938d8b5ba3 fc-tmsh: set-pcm-string and set-rfcap implemented
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 263
diff changeset
26 extern void cmd_set_pcm_string();
0c938d8b5ba3 fc-tmsh: set-pcm-string and set-rfcap implemented
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 263
diff changeset
27 extern void cmd_set_rfcap();
189
a95d253ef952 fc-tmsh: some basic tmcore commands implemented
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 182
diff changeset
28 extern void cmd_tgtreset();
a95d253ef952 fc-tmsh: some basic tmcore commands implemented
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 182
diff changeset
29 extern void cmd_version();
192
707aa640b2dc fc-tmsh: w8/w16/w32 implemented
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 189
diff changeset
30 extern void cmd_w8();
707aa640b2dc fc-tmsh: w8/w16/w32 implemented
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 189
diff changeset
31 extern void cmd_w16();
707aa640b2dc fc-tmsh: w8/w16/w32 implemented
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 189
diff changeset
32 extern void cmd_w32();
182
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
33
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
34 void
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
35 cmd_exit()
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
36 {
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
37 tty_cleanup();
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
38 exit(0);
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
39 }
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
40
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
41 static struct cmdtab {
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
42 char *cmd;
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
43 int minargs;
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
44 int maxargs;
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
45 void (*func)();
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
46 } cmdtab[] = {
198
c9ea2f7441a5 fc-tmsh: abb[rw] commands implemented
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 192
diff changeset
47 {"abbr", 2, 2, cmd_abbr},
c9ea2f7441a5 fc-tmsh: abb[rw] commands implemented
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 192
diff changeset
48 {"abbw", 3, 3, cmd_abbw},
257
c413e791595a fc-tmsh: added check-ffs1 command, getting ready to begin ffs2 implementation
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 198
diff changeset
49 {"check-ffs1", 0, 0, cmd_check_ffs1},
189
a95d253ef952 fc-tmsh: some basic tmcore commands implemented
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 182
diff changeset
50 {"dieid", 0, 0, cmd_dieid},
182
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
51 {"etmpkt", 1, 253, cmd_etmpkt},
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
52 {"exit", 0, 0, cmd_exit},
259
35113b1964d3 fc-tmsh ffs2: a few request-sending commands implemented
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 258
diff changeset
53 {"ffs2", 1, 3, cmd_ffs2},
978
1ee80bcb0fd0 fc-tmsh: omr (old-style memory read) command implemented
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents: 267
diff changeset
54 {"omr", 2, 2, cmd_omr},
189
a95d253ef952 fc-tmsh: some basic tmcore commands implemented
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 182
diff changeset
55 {"ping", 0, 2, cmd_ping},
182
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
56 {"quit", 0, 0, cmd_exit},
189
a95d253ef952 fc-tmsh: some basic tmcore commands implemented
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 182
diff changeset
57 {"r8", 1, 2, cmd_r8},
a95d253ef952 fc-tmsh: some basic tmcore commands implemented
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 182
diff changeset
58 {"r16", 1, 2, cmd_r16},
a95d253ef952 fc-tmsh: some basic tmcore commands implemented
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 182
diff changeset
59 {"r32", 1, 2, cmd_r32},
263
b5b54feb111a fc-tmsh: set-imeisv command implemented
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 260
diff changeset
60 {"set-imeisv", 2, 2, cmd_set_imeisv},
264
0c938d8b5ba3 fc-tmsh: set-pcm-string and set-rfcap implemented
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 263
diff changeset
61 {"set-pcm-string", 2, 2, cmd_set_pcm_string},
0c938d8b5ba3 fc-tmsh: set-pcm-string and set-rfcap implemented
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 263
diff changeset
62 {"set-rfcap", 16, 16, cmd_set_rfcap},
189
a95d253ef952 fc-tmsh: some basic tmcore commands implemented
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 182
diff changeset
63 {"tgtreset", 0, 0, cmd_tgtreset},
a95d253ef952 fc-tmsh: some basic tmcore commands implemented
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 182
diff changeset
64 {"version", 1, 1, cmd_version},
192
707aa640b2dc fc-tmsh: w8/w16/w32 implemented
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 189
diff changeset
65 {"w8", 2, 246, cmd_w8},
707aa640b2dc fc-tmsh: w8/w16/w32 implemented
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 189
diff changeset
66 {"w16", 2, 123, cmd_w16},
707aa640b2dc fc-tmsh: w8/w16/w32 implemented
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 189
diff changeset
67 {"w32", 2, 62, cmd_w32},
182
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
68 {0, 0, 0, 0}
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
69 };
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
70
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
71 void
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
72 dispatch_user_cmd()
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
73 {
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
74 char *argv[257];
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
75 char *cp, **ap;
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
76 struct cmdtab *tp;
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
77
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
78 for (cp = usercmd; isspace(*cp); cp++)
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
79 ;
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
80 if (!*cp || *cp == '#')
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
81 return;
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
82 argv[0] = cp;
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
83 while (*cp && !isspace(*cp))
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
84 cp++;
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
85 if (*cp)
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
86 *cp++ = '\0';
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
87 for (tp = cmdtab; tp->cmd; tp++)
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
88 if (!strcmp(tp->cmd, argv[0]))
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
89 break;
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
90 if (!tp->func) {
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
91 printf("error: no such command\n");
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
92 return;
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
93 }
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
94 for (ap = argv + 1; ; ) {
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
95 while (isspace(*cp))
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
96 cp++;
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
97 if (!*cp || *cp == '#')
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
98 break;
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
99 if (ap - argv - 1 >= tp->maxargs) {
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
100 printf("error: too many arguments\n");
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
101 return;
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
102 }
267
4c6bee98e002 fc-tmsh: support quoted strings for set-pcm-string
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 264
diff changeset
103 if (*cp == '"') {
4c6bee98e002 fc-tmsh: support quoted strings for set-pcm-string
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 264
diff changeset
104 *ap++ = ++cp;
4c6bee98e002 fc-tmsh: support quoted strings for set-pcm-string
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 264
diff changeset
105 while (*cp && *cp != '"')
4c6bee98e002 fc-tmsh: support quoted strings for set-pcm-string
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 264
diff changeset
106 cp++;
4c6bee98e002 fc-tmsh: support quoted strings for set-pcm-string
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 264
diff changeset
107 if (*cp != '"') {
4c6bee98e002 fc-tmsh: support quoted strings for set-pcm-string
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 264
diff changeset
108 printf("error: unterminated quoted string\n");
4c6bee98e002 fc-tmsh: support quoted strings for set-pcm-string
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 264
diff changeset
109 return;
4c6bee98e002 fc-tmsh: support quoted strings for set-pcm-string
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 264
diff changeset
110 }
182
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
111 *cp++ = '\0';
267
4c6bee98e002 fc-tmsh: support quoted strings for set-pcm-string
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 264
diff changeset
112 } else {
4c6bee98e002 fc-tmsh: support quoted strings for set-pcm-string
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 264
diff changeset
113 *ap++ = cp;
4c6bee98e002 fc-tmsh: support quoted strings for set-pcm-string
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 264
diff changeset
114 while (*cp && !isspace(*cp))
4c6bee98e002 fc-tmsh: support quoted strings for set-pcm-string
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 264
diff changeset
115 cp++;
4c6bee98e002 fc-tmsh: support quoted strings for set-pcm-string
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 264
diff changeset
116 if (*cp)
4c6bee98e002 fc-tmsh: support quoted strings for set-pcm-string
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 264
diff changeset
117 *cp++ = '\0';
4c6bee98e002 fc-tmsh: support quoted strings for set-pcm-string
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 264
diff changeset
118 }
182
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
119 }
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
120 if (ap - argv - 1 < tp->minargs) {
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
121 printf("error: too few arguments\n");
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
122 return;
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
123 }
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
124 *ap = 0;
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
125 tp->func(ap - argv, argv);
13a0348ffce4 rvinterf/etm: checkpointing not-yet-compilable code
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
126 }