util: move read_password method out of qemu-img into osdep/oslib
commitd57e4e482e3997b1382625c84149ad0b69155fc0
authorDaniel P. Berrange <berrange@redhat.com>
Tue, 12 May 2015 16:09:19 +0000 (12 17:09 +0100)
committerKevin Wolf <kwolf@redhat.com>
Fri, 22 May 2015 15:08:01 +0000 (22 17:08 +0200)
tree3ce7f69edf3c4e628e464f3c0d846a23a7c74cba
parent8336aafae1451d54c81dd2b187b45f7c45d2428e
util: move read_password method out of qemu-img into osdep/oslib

The qemu-img.c file has a read_password() method impl that is
used to prompt for passwords on the console, with impls for
POSIX and Windows. This will be needed by qemu-io.c too, so
move it into the QEMU osdep/oslib files where it can be shared
without code duplication

Signed-off-by: Daniel P. Berrange <berrange@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
include/qemu/osdep.h
qemu-img.c
util/oslib-posix.c
util/oslib-win32.c