On Thu, 2017-12-14 at 14:55 +0100, Bjoern Walk wrote: > > + * Returns: 0 when the string has been parsed successfully and the CPU > > + * frequency has been stored in @mhz, >0 when the string has not > > Maybe, >0 when the line prefix does not match exactly? Documentation goes out of sync with reality quickly enough when the language used is purposefully vague ;) > > + /* Skip the colon. If anything but a colon is found, then we're > > + * not looking at the right string and we should move on */ > > + if (*str != ':') > > + return 1; > > + str++; > > You could do *str++ != ':' and save one line. I'd rather not. Lines are cheap :) -- Andrea Bolognani / Red Hat / Virtualization -- libvir-list mailing list libvir-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/libvir-list