[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH] bug fix for a buffer overflow in ivona_client.c
From: |
Trevor Saunders |
Subject: |
[PATCH] bug fix for a buffer overflow in ivona_client.c |
Date: |
Thu, 2 Sep 2010 12:39:18 -0400 |
i,
On Thu, Sep 02, 2010 at 06:11:51AM -0500, Christopher Brannon wrote:
> Trevor Saunders <trev.saunders at gmail.com> writes:
>
> > + int len = strlen(IvonaSoundIconPath) + strlen(name) + 2;
> > + char *buf = g_malloc(len);
> > +sprintf(buf, "%s/%s", IvonaSoundIconPath, name);
>
> I'd suggest replacing these three lines with:
> char *buf = g_strdup_printf("%s/%s", IvonaSoundIconPath, name);
that's a little cleaner I gues, but I don't really care myself.
Trev
>
> -- Chris
> _______________________________________________
> Speechd mailing list
> Speechd at lists.freebsoft.org
> http://lists.freebsoft.org/mailman/listinfo/speechd
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: Digital signature
URL:
<http://lists.freebsoft.org/pipermail/speechd/attachments/20100902/27f85b67/attachment.pgp>