]> git.ipfire.org Git - thirdparty/libvirt.git/commit
perf: get rid of pointless virPerfGetEvent() method
authorDaniel P. Berrange <berrange@redhat.com>
Fri, 16 Dec 2016 10:58:29 +0000 (10:58 +0000)
committerDaniel P. Berrange <berrange@redhat.com>
Wed, 12 Apr 2017 15:33:05 +0000 (16:33 +0100)
commitbdcf6e481072d9d98a0dc60f08572340d55fb48f
tree5d99c7bf4bce0e8338809bdd004c648d65d5e97e
parent5fca70ef57d735e023e672d7f39a513e0c750951
perf: get rid of pointless virPerfGetEvent() method

The virPerfGetEvent method pointlessly checks for a NULL
parameter and the range of an enum value. The whole point
of using an enum is that we can avoid such checks. Just
replace calls to virPerfGetEvent, with perf->events[type]
array access.

Signed-off-by: Daniel P. Berrange <berrange@redhat.com>
src/util/virperf.c