diff options
author | Peter Maydell <peter.maydell@linaro.org> | 2016-07-12 13:02:16 +0100 |
---|---|---|
committer | Riku Voipio <riku.voipio@linaro.org> | 2016-08-04 16:36:26 +0300 |
commit | 332c9781f6a7c496adf605a1be72776598c7adc2 (patch) | |
tree | 87817914c04fd6135a714602e01bbb1cb2f690bd /linux-user/x86_64 | |
parent | ba4b3f668abf1fcde204c8f3185ea6edeec6eaa3 (diff) | |
download | qemu-332c9781f6a7c496adf605a1be72776598c7adc2.zip qemu-332c9781f6a7c496adf605a1be72776598c7adc2.tar.gz qemu-332c9781f6a7c496adf605a1be72776598c7adc2.tar.bz2 |
linux-user: Don't write off end of new_utsname buffer
Use g_strlcpy() rather than strcpy() to copy the uname string
into the structure we return to the guest for the uname syscall.
This avoids overrunning the buffer if the user passed us an
overlong string via the QEMU command line.
We fix a comment typo while we're in the neighbourhood.
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Signed-off-by: Riku Voipio <riku.voipio@linaro.org>
Diffstat (limited to 'linux-user/x86_64')
0 files changed, 0 insertions, 0 deletions