jiangpengfei 5712b1198e qemu/qmp: fix readLoop() reuse scanner.Bytes() underlying array problem
Since []byte channel type transfer slice info(include slice underlying array pointer, len, cap)
between channel sender and receiver. scanner.Bytes() function returned slice's underlying array
may point to data that will be overwritten by a subsequent call to Scan(reference from:
https://golang.org/pkg/bufio/#Scanner.Bytes), which may make consecutive scan() call write the
read data into the same underlying array which causes receiver read mixed data,so we need to
copy line to new allocated space and then send to channel receiver to solve this problem.

Fixes: #88

Signed-off-by: jiangpengfei <jiangpengfei9@huawei.com>
2019-03-13 19:45:05 -04:00
2017-12-11 11:05:31 +00:00
2018-11-30 09:34:21 +01:00
2018-12-06 11:35:15 +08:00
2017-12-11 11:05:31 +00:00

Virtual Machine Manager for Go

Go Report Card Build Status GoDoc Coverage Status

Virtual Machine Manager for Go (govmm) is a suite of packages that provide Go APIs for creating and managing virtual machines. There's currently support for only one hypervisor, qemu/kvm, support for which is provided by the github.com/intel/govmm/qemu package.

The qemu package provides APIs for launching qemu instances and for managing those instances via QMP, once launched. VM instances can be stopped, have devices attached to them and monitored for events via the qemu APIs.

The qemu package has no external dependencies apart from the Go standard library and so is nice and easy to vendor inside other projects.

Languages
Rust 58.5%
Go 24.3%
Shell 10%
RPC 5.3%
Makefile 1%
Other 0.8%