]> git.ipfire.org Git - thirdparty/libvirt.git/commit
virsh: avoid strtol
authorEric Blake <eblake@redhat.com>
Wed, 18 Apr 2012 23:26:17 +0000 (17:26 -0600)
committerEric Blake <eblake@redhat.com>
Thu, 19 Apr 2012 23:42:53 +0000 (17:42 -0600)
commitbb65c8af33d53d3dc140ae003bc4ff3509f1eb7d
tree7dc5b85c4fc21ff9c6db0e194c825a0d9a8b4e79
parent1aeacfd5e97ede2a62f0e0e2cb39dc508a317268
virsh: avoid strtol

We were forgetting to check errno for overflow.

* tools/virsh.c (get_integer_keycode, vshCommandOptInt)
(vshCommandOptUInt, vshCommandOptUL, vshCommandOptLongLong)
(vshCommandOptULongLong): Rewrite to be safer.
tools/virsh.c