aboutsummaryrefslogtreecommitdiff
path: root/block-vmdk.c
diff options
context:
space:
mode:
authorblueswir1 <blueswir1@c046a42c-6fe2-441c-8c8c-71466251a162>2008-10-25 11:21:28 +0000
committerblueswir1 <blueswir1@c046a42c-6fe2-441c-8c8c-71466251a162>2008-10-25 11:21:28 +0000
commitbe15b141e0dddd9f41e464ca98aef1b05b28cf6b (patch)
tree94b26dd8001eef4275e68fe03cf85990d4bfea5a /block-vmdk.c
parent9b4c14c35bff99476b0223e87532f8d53a9909c4 (diff)
downloadqemu-be15b141e0dddd9f41e464ca98aef1b05b28cf6b.zip
qemu-be15b141e0dddd9f41e464ca98aef1b05b28cf6b.tar.gz
qemu-be15b141e0dddd9f41e464ca98aef1b05b28cf6b.tar.bz2
Replace uses of strncpy (a GNU extension) with Qemu pstrcpy
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5531 c046a42c-6fe2-441c-8c8c-71466251a162
Diffstat (limited to 'block-vmdk.c')
-rw-r--r--block-vmdk.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/block-vmdk.c b/block-vmdk.c
index c49b671..2a257b6 100644
--- a/block-vmdk.c
+++ b/block-vmdk.c
@@ -344,7 +344,7 @@ static int vmdk_parent_open(BlockDriverState *bs, const char * filename)
if ((end_name - p_name) > sizeof (s->hd->backing_file) - 1)
return -1;
- strncpy(s->hd->backing_file, p_name, end_name - p_name);
+ pstrcpy(s->hd->backing_file, end_name - p_name, p_name);
if (stat(s->hd->backing_file, &file_buf) != 0) {
path_combine(parent_img_name, sizeof(parent_img_name),
filename, s->hd->backing_file);