simpletrace: Move st_init() error reporting

User emulator builds do not have error_report() so it should not be used
by simpletrace.c.  In fact, error reporting inside simpletrace.c is
inappropriate and should be done by the caller instead.

This patch moves st_init() error reporting out to its caller,
vl.c:main().

Reported-by: Blue Swirl <blauwirbel@gmail.com>
Signed-off-by: Stefan Hajnoczi <stefanha@linux.vnet.ibm.com>
Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
This commit is contained in:
Stefan Hajnoczi 2011-03-13 20:14:30 +00:00 committed by Blue Swirl
parent cc015e9a5d
commit 31d3c9b8c1
3 changed files with 9 additions and 8 deletions

4
vl.c
View file

@ -2766,7 +2766,9 @@ int main(int argc, char **argv, char **envp)
}
loc_set_none();
st_init(trace_file);
if (!st_init(trace_file)) {
fprintf(stderr, "warning: unable to initialize simple trace backend\n");
}
/* If no data_dir is specified then try to find it relative to the
executable path. */