Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 196006 Details for
Bug 272050
x11-misc/electricsheep is too old
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
electricsheep-9999-valgrind.patch
electricsheep-9999-valgrind.patch (text/plain), 2.79 KB, created by
David Leverton
on 2009-06-28 21:13:38 UTC
(
hide
)
Description:
electricsheep-9999-valgrind.patch
Filename:
MIME Type:
Creator:
David Leverton
Created:
2009-06-28 21:13:38 UTC
Size:
2.79 KB
patch
obsolete
>Index: client/utils.c >=================================================================== >--- client/utils.c (revision 1257) >+++ client/utils.c (working copy) >@@ -30,6 +30,7 @@ > #include <sys/time.h> > #include <time.h> > #include <sys/wait.h> >+#include <stdint.h> > > #include <expat.h> > >@@ -70,14 +71,19 @@ > if (!strcmp("preferences", name)) { > while (atts[i]) { > if (!strcmp("nick", atts[i])) { >+ free(prefs->nick); > prefs->nick = strdup(atts[i+1]); > } else if (!strcmp("url", atts[i])) { >+ free(prefs->url); > prefs->url = strdup(atts[i+1]); > } else if (!strcmp("password", atts[i])) { >+ free(prefs->password); > prefs->password = strdup(atts[i+1]); > } else if (!strcmp("video_driver", atts[i])) { >+ free(prefs->video_driver); > prefs->video_driver = strdup(atts[i+1]); > } else if (!strcmp("uid", atts[i])) { >+ free(prefs->uid); > prefs->uid = strdup(atts[i+1]); > } else if (!strcmp("cache", atts[i])) { > prefs->cache_size = atoi(atts[i+1]); >@@ -168,7 +174,7 @@ > /* 64 random bits encoded as ascii */ > void make_uniqueid(prefs_t *prefs) { > static char *rdevice = "/dev/urandom"; >- unsigned long d[2]; >+ uint32_t d[2]; > int rfd; > struct timeval tv; > char ub[17]; >@@ -190,15 +196,20 @@ > d[0] ^= tv.tv_sec; > d[1] ^= tv.tv_usec; > snprintf(ub, 17, "%08lX%08lX", d[0], d[1]); >+ free(prefs->uid); > prefs->uid = strdup(ub); > } > > void default_rc(prefs_t *prefs) { >- prefs->nick = ""; >- prefs->url = ""; >- prefs->password = ""; >+ free(prefs->nick); >+ prefs->nick = strdup(""); >+ free(prefs->url); >+ prefs->url = strdup(""); >+ free(prefs->password); >+ prefs->password = strdup(""); > prefs->cache_size = 2000; >- prefs->video_driver = ""; >+ free(prefs->video_driver); >+ prefs->video_driver = strdup(""); > make_uniqueid(prefs); > prefs->frame_rate = 23.0; > prefs->nrepeats = 2; >Index: client/electricsheep.c >=================================================================== >--- client/electricsheep.c (revision 1257) >+++ client/electricsheep.c (working copy) >@@ -735,6 +735,7 @@ > exit(1); > } > av_free_packet(&opkt); >+ av_free_packet(&ipkt); > } > av_close_input_file(ictx); > } >Index: client/electricsheep-preferences.c >=================================================================== >--- client/electricsheep-preferences.c (revision 1257) >+++ client/electricsheep-preferences.c (working copy) >@@ -52,11 +52,16 @@ > GtkButton *test_button; > > void clear_prefs(prefs_t *prefs) { >+ free(prefs->nick); > prefs->nick = NULL; >+ free(prefs->url); > prefs->url = NULL; >+ free(prefs->password); > prefs->password = NULL; >+ free(prefs->video_driver); > prefs->video_driver = NULL; > prefs->cache_size = -1; >+ free(prefs->uid); > prefs->uid = NULL; > prefs->frame_rate = -1.0; > prefs->play_evenly = 1.0;
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 272050
:
195999
|
196001
|
196003
|
196005
|
196006
|
196008
|
197411
|
197863