trace: Fix build warnings for Win32 build

The Win32 build warns about trace/control-internal.h:

warning: 'trace_event_count' declared inline after being called

Fix this by simply reordering trace_event_id() and
trace_event_count().

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Stefan Weil <sw@weilnetz.de>
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
This commit is contained in:
Peter Maydell 2014-02-20 19:44:25 +00:00 committed by Stefan Hajnoczi
parent 2396187076
commit 84f3fe1b07
1 changed files with 5 additions and 5 deletions

View File

@ -16,17 +16,17 @@
extern TraceEvent trace_events[];
static inline TraceEventID trace_event_count(void)
{
return TRACE_EVENT_COUNT;
}
static inline TraceEvent *trace_event_id(TraceEventID id)
{
assert(id < trace_event_count());
return &trace_events[id];
}
static inline TraceEventID trace_event_count(void)
{
return TRACE_EVENT_COUNT;
}
static inline bool trace_event_is_pattern(const char *str)
{
assert(str != NULL);