]> sjero.net Git - wget/commitdiff
[svn] Free the old value of opt.useragent before setting the new one.
authorhniksic <devnull@localhost>
Wed, 27 Apr 2005 22:16:28 +0000 (15:16 -0700)
committerhniksic <devnull@localhost>
Wed, 27 Apr 2005 22:16:28 +0000 (15:16 -0700)
src/ChangeLog
src/init.c

index 6d224fe79f8c5cb78ddcfefab4f23b27aadbf365..641b09919cc5dd2bd79b727ca488edbc6f422d6d 100644 (file)
@@ -1,3 +1,8 @@
+2005-04-27  Hrvoje Niksic  <hniksic@xemacs.org>
+
+       * init.c (cmd_spec_useragent): Free the old value of
+       opt.useragent before setting the new one.
+
 2005-04-27  Mauro Tortonesi  <mauro@ferrara.linux.it>
 
        * main.c: Map --ftp-password, --http-password and --proxy-password to
index c0bbee525eb16367ceb94444f3d434964a76951f..14f3a87b990b9fc7693391e344e1f98b672001f2 100644 (file)
@@ -1258,6 +1258,7 @@ cmd_spec_useragent (const char *com, const char *val, void *place_ignored)
               exec_name, com, val);
       return 0;
     }
+  xfree_null (opt.useragent);
   opt.useragent = xstrdup (val);
   return 1;
 }