summaryrefslogtreecommitdiff
path: root/stdscan.c
diff options
context:
space:
mode:
Diffstat (limited to 'stdscan.c')
-rw-r--r--stdscan.c12
1 files changed, 11 insertions, 1 deletions
diff --git a/stdscan.c b/stdscan.c
index 0f7b3bd..f50dd85 100644
--- a/stdscan.c
+++ b/stdscan.c
@@ -50,10 +50,21 @@
* formats. It keeps a succession of temporary-storage strings in
* stdscan_tempstorage, which can be cleared using stdscan_reset.
*/
+static char *stdscan_bufptr = NULL;
static char **stdscan_tempstorage = NULL;
static int stdscan_tempsize = 0, stdscan_templen = 0;
#define STDSCAN_TEMP_DELTA 256
+void stdscan_set(char *str)
+{
+ stdscan_bufptr = str;
+}
+
+char *stdscan_get(void)
+{
+ return stdscan_bufptr;
+}
+
static void stdscan_pop(void)
{
nasm_free(stdscan_tempstorage[--stdscan_templen]);
@@ -94,7 +105,6 @@ static char *stdscan_copy(char *p, int len)
return text;
}
-char *stdscan_bufptr = NULL;
int stdscan(void *private_data, struct tokenval *tv)
{
char ourcopy[MAX_KEYWORD + 1], *r, *s;