]> xenbits.xensource.com Git - people/liuw/libxenctrl-split/libvirt.git/commit
Replace sscanf in PCI device address parsing
authorMatthias Bolte <matthias.bolte@googlemail.com>
Tue, 30 Mar 2010 15:31:19 +0000 (17:31 +0200)
committerMatthias Bolte <matthias.bolte@googlemail.com>
Thu, 1 Apr 2010 10:53:41 +0000 (12:53 +0200)
commitd13eb9fc95873d11779f0ff1a5c0df65c3b42a8f
treeea37b4f8cc3ea6e728e033acb7b1ff880b086bda
parent57dab748049d9f815b58dcf781bdb5ff3c8d1d2f
Replace sscanf in PCI device address parsing

This also fixes a problem with MinGW's GCC on Windows. GCC complains
about the L modifier being unknown.

Parsing in pciIterDevices is stricter now and doesn't accept trailing
characters after the actual <domain>:<bus>:<slot>.<function> sequence
anymore.

Parsing in pciWaitForDeviceCleanup is also stricter now and expects
the <start>-<end> : <domain>:<bus>:<slot>.<function> sequence to be
terminated by \n.

Change domain from unsigned long long to unsigned int in
pciWaitForDeviceCleanup, because everywhere else domain is handled as
unsigned int too.
src/util/pci.c