TB print hello world
This commit is contained in:
@ -13,6 +13,7 @@
|
||||
#include <dlmalloc/malloc.h>
|
||||
#include <errors.h>
|
||||
#include <util/util.h>
|
||||
#include "interp.h"
|
||||
|
||||
struct {
|
||||
char *modestr;
|
||||
@ -74,6 +75,14 @@ void do_file(char *filepath) {
|
||||
goto done;
|
||||
}
|
||||
|
||||
InterpResult *res;
|
||||
bool ok = interp_runstring((const char *)buf, statbuf.size, &res);
|
||||
if (!ok) {
|
||||
uprintf("Interpreter error:\n");
|
||||
uprintf("%s\n", res->errmsg);
|
||||
goto done;
|
||||
}
|
||||
|
||||
done:
|
||||
dlfree(buf);
|
||||
ioctl(ioh, IOCTL_CLOSEF, 0, 0, 0);
|
||||
|
Reference in New Issue
Block a user