Mercurial > repos > rhope
comparison string.c @ 29:3cc5e4a42344
Missed registration for *@Real Number in previous commit
author | Mike Pavone <pavone@retrodev.com> |
---|---|
date | Sat, 27 Jun 2009 01:50:33 -0400 |
parents | 94c885692eb5 |
children |
comparison
equal
deleted
inserted
replaced
28:d8b4d38fceb6 | 29:3cc5e4a42344 |
---|---|
46 } | 46 } |
47 | 47 |
48 #ifndef SEGA | 48 #ifndef SEGA |
49 int vis_realtostring(datum ** inputlist, queue_entry * worker_entry) | 49 int vis_realtostring(datum ** inputlist, queue_entry * worker_entry) |
50 { | 50 { |
51 char temp_buf[30];//Is this enough? | 51 char temp_buf[512];//Is this enough? |
52 datum * output; | 52 datum * output; |
53 sprintf(temp_buf, "%f", inputlist[0]->c.real); | 53 sprintf(temp_buf, "%f", inputlist[0]->c.real); |
54 release_ref(inputlist[0]); | 54 release_ref(inputlist[0]); |
55 inputlist[0] = new_datum(BUILTIN_TYPE_STRING, 1, strlen(temp_buf)+1, worker_entry->instance->def->program); | 55 inputlist[0] = new_datum(BUILTIN_TYPE_STRING, 1, strlen(temp_buf)+1, worker_entry->instance->def->program); |
56 strcpy(inputlist[0]->c.generic.data, temp_buf); | 56 strcpy(inputlist[0]->c.generic.data, temp_buf); |