aboutsummaryrefslogtreecommitdiff
path: root/qemu-error.h
diff options
context:
space:
mode:
authorMarkus Armbruster <armbru@redhat.com>2010-02-18 20:13:51 +0100
committerMarkus Armbruster <armbru@redhat.com>2010-03-16 16:58:32 +0100
commit0f0bc3f1d526924ef4a75ad25dd0ec3771a66496 (patch)
tree130684a948ba840c06ea12c31e0dfbd24b2e3027 /qemu-error.h
parentef82516d8fb41cbae9703d07516641f6bdf91a77 (diff)
downloadqemu-0f0bc3f1d526924ef4a75ad25dd0ec3771a66496.zip
qemu-0f0bc3f1d526924ef4a75ad25dd0ec3771a66496.tar.gz
qemu-0f0bc3f1d526924ef4a75ad25dd0ec3771a66496.tar.bz2
error: Track locations on command line
New LOC_CMDLINE. Use it for tracking option with argument in lookup_opt(). We now report errors like this qemu: -device smbus-eeprom: Did not find I2C bus for smbus-eeprom
Diffstat (limited to 'qemu-error.h')
-rw-r--r--qemu-error.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/qemu-error.h b/qemu-error.h
index 8f2a140..88e0b70 100644
--- a/qemu-error.h
+++ b/qemu-error.h
@@ -15,7 +15,7 @@
typedef struct Location {
/* all members are private to qemu-error.c */
- enum { LOC_NONE, LOC_FILE } kind;
+ enum { LOC_NONE, LOC_CMDLINE, LOC_FILE } kind;
int num;
const void *ptr;
struct Location *prev;
@@ -27,6 +27,7 @@ Location *loc_pop(Location *loc);
Location *loc_save(Location *loc);
void loc_restore(Location *loc);
void loc_set_none(void);
+void loc_set_cmdline(char **argv, int idx, int cnt);
void loc_set_file(const char *fname, int lno);
void error_vprintf(const char *fmt, va_list ap);