aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormalc <malc@c046a42c-6fe2-441c-8c8c-71466251a162>2008-09-28 00:42:15 +0000
committermalc <malc@c046a42c-6fe2-441c-8c8c-71466251a162>2008-09-28 00:42:15 +0000
commit2d6f89714186bc51d20d34641bf4ab5a726ab54a (patch)
treee2fd97a3a60679b1329eef6ea98f11b6ccb48846
parentcb5a7aa8c32141bb19a8f6571f630c779faebc25 (diff)
Fix more r5087 breakage
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5337 c046a42c-6fe2-441c-8c8c-71466251a162
-rw-r--r--audio/audio.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/audio/audio.c b/audio/audio.c
index 20bb2fc264..b3ac10e128 100644
--- a/audio/audio.c
+++ b/audio/audio.c
@@ -212,7 +212,7 @@ static char *audio_alloc_prefix (const char *s)
char *u = r + sizeof (qemu_prefix) - 1;
pstrcpy (r, len + sizeof (qemu_prefix), qemu_prefix);
- pstrcat (r, len, s);
+ pstrcat (r, len + sizeof (qemu_prefix), s);
for (i = 0; i < len; ++i) {
u[i] = toupper (u[i]);
@@ -467,16 +467,13 @@ static void audio_process_options (const char *prefix,
}
pstrcpy (optname, optlen, qemu_prefix);
- optlen -= preflen;
/* copy while upper-casing, including trailing zero */
for (i = 0; i <= preflen; ++i) {
optname[i + sizeof (qemu_prefix) - 1] = toupper (prefix[i]);
}
pstrcat (optname, optlen, "_");
- optlen--;
pstrcat (optname, optlen, opt->name);
- optlen -= len;
def = 1;
switch (opt->tag) {