1. 06 Dec, 2011 7 commits
  2. 01 Dec, 2011 4 commits
  3. 29 Nov, 2011 8 commits
  4. 25 Nov, 2011 1 commit
  5. 24 Nov, 2011 7 commits
    • Paulo Zanoni's avatar
      parser: free val.str after xstrtokenize · 873a1ace
      Paulo Zanoni authored
      
      
      After we tokenize val.str, we discard it.
      
      This is just one example:
      6 bytes in 1 blocks are definitely lost in loss record 24 of 652
         at 0x4C2779D: malloc (in vgpreload_memcheck-amd64-linux.so)
         by 0x4D744D: xf86getToken (scan.c:400)
         by 0x4D75F1: xf86getSubToken (scan.c:462)
         by 0x4DB060: xf86parseInputClassSection (InputClass.c:145)
         by 0x4D664C: xf86readConfigFile (read.c:184)
         by 0x490556: xf86HandleConfigFile (xf86Config.c:2360)
         by 0x49AA77: InitOutput (xf86Init.c:365)
         by 0x425A7A: main (main.c:204)
      Signed-off-by: Paulo Zanoni's avatarPaulo Zanoni <paulo.r.zanoni@intel.com>
      Reviewed-by: Peter Hutterer's avatarPeter Hutterer <peter.hutterer@who-t.net>
      Reviewed-by: Dan Nicholson's avatarDan Nicholson <dbn.lists@gmail.com>
      873a1ace
    • Paulo Zanoni's avatar
      parser: free val.str after xf86getBoolValue · d41987d7
      Paulo Zanoni authored
      
      
      After we convert the value to a boolean, we discard the string.
      
      This is just one example:
      
      3 bytes in 1 blocks are definitely lost in loss record 5 of 657
         at 0x4C2779D: malloc (vgpreload_memcheck-amd64-linux.so)
         by 0x4D744D: xf86getToken (scan.c:400)
         by 0x4D75F1: xf86getSubToken (scan.c:462)
         by 0x4DB3E0: xf86parseInputClassSection (InputClass.c:189)
         by 0x4D664C: xf86readConfigFile (read.c:184)
         by 0x490556: xf86HandleConfigFile (xf86Config.c:2360)
         by 0x49AA77: InitOutput (xf86Init.c:365)
         by 0x425A7A: main (main.c:204)
      Signed-off-by: Paulo Zanoni's avatarPaulo Zanoni <paulo.r.zanoni@intel.com>
      Reviewed-by: Peter Hutterer's avatarPeter Hutterer <peter.hutterer@who-t.net>
      Reviewed-by: Dan Nicholson's avatarDan Nicholson <dbn.lists@gmail.com>
      d41987d7
    • Paulo Zanoni's avatar
      parser: free scandir's list · d5c7338b
      Paulo Zanoni authored
      
      
      v2: move the free()s to the function that calls scandir
      
      80 bytes in 1 blocks are definitely lost in loss record 411 of 631
         at 0x4C2779D: malloc (vgpreload_memcheck-amd64-linux.so)
         by 0x4C27927: realloc (vgpreload_memcheck-amd64-linux.so)
         by 0x696A80D: scandir (scandir.c:108)
         by 0x4D8828: OpenConfigDir (scan.c:854)
         by 0x4D8A43: xf86openConfigDirFiles (scan.c:952)
         by 0x49031F: xf86HandleConfigFile (xf86Config.c:2327)
         by 0x49A9E3: InitOutput (xf86Init.c:365)
         by 0x425A7A: main (main.c:204)
      Signed-off-by: Paulo Zanoni's avatarPaulo Zanoni <paulo.r.zanoni@intel.com>
      Reviewed-by: Peter Hutterer's avatarPeter Hutterer <peter.hutterer@who-t.net>
      d5c7338b
    • Paulo Zanoni's avatar
      Correctly free config file names · 3d635fe8
      Paulo Zanoni authored
      
      
      We call xf86penConfigDirFiles twice, so we overwrite the configDirPath
      variable, losing the pointer. If we move the pointer management to the
      upper layer (the function callers), they will be able to call these
      functions as many times as they want, but they'll have to free those
      returned values.
      
      v2: don't leak inside XWin
      
      4,097 bytes in 1 blocks are definitely lost in loss record 625 of 632
         at 0x4C2779D: malloc (in vgpreload_memcheck-amd64-linux.so)
         by 0x4D7899: DoSubstitution (scan.c:615)
         by 0x4D87B0: OpenConfigDir (scan.c:845)
         by 0x4D8A2D: xf86openConfigDirFiles (scan.c:955)
         by 0x49031F: xf86HandleConfigFile (xf86Config.c:2327)
         by 0x49A9BF: InitOutput (xf86Init.c:365)
         by 0x425A7A: main (main.c:204)
      Signed-off-by: Paulo Zanoni's avatarPaulo Zanoni <paulo.r.zanoni@intel.com>
      Reviewed-by: Dan Nicholson's avatarDan Nicholson <dbn.lists@gmail.com>
      3d635fe8
    • Paulo Zanoni's avatar
      glx: don't leak driConfigs · 0ae087e1
      Paulo Zanoni authored
      
      
      For dri, dri2 and driswrast.
      
      12,968 (584 direct, 12,384 indirect) bytes in 1 blocks are definitely lost in loss record 569 of 570
         at 0x4C2779D: malloc (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
         by 0x7821E3B: driConcatConfigs (utils.c:560)
         by 0x7827CF2: dri_fill_in_modes (dri_screen.c:224)
         by 0x782831E: dri_init_screen_helper (dri_screen.c:405)
         by 0x7826C03: drisw_init_screen (drisw.c:266)
         by 0x782225F: driCreateNewScreen (drisw_util.c:69)
         by 0x4826E2: __glXDRIscreenProbe (glxdriswrast.c:451)
         by 0x4812FA: GlxExtensionInit (glxext.c:327)
         by 0x41FB14: InitExtensions (miinitext.c:471)
         by 0x568622: main (main.c:208)
      Signed-off-by: Paulo Zanoni's avatarPaulo Zanoni <paulo.r.zanoni@intel.com>
      Reviewed-by: Jeremy Huddleston Sequoia's avatarJeremy Huddleston <jeremyhu@apple.com>
      0ae087e1
    • Paulo Zanoni's avatar
      glx: don't leak fbconfigs · d26fae24
      Paulo Zanoni authored
      
      
      29,952 (208 direct, 29,744 indirect) bytes in 1 blocks are definitely lost in loss record 573 of 573
         at 0x4C2779D: malloc (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
         by 0x4829BC: createModeFromConfig (glxdricommon.c:131)
         by 0x482C09: glxConvertConfigs (glxdricommon.c:185)
         by 0x482788: __glXDRIscreenProbe (glxdriswrast.c:468)
         by 0x4812FA: GlxExtensionInit (glxext.c:327)
         by 0x41FB14: InitExtensions (miinitext.c:471)
         by 0x568636: main (main.c:208)
      Signed-off-by: Paulo Zanoni's avatarPaulo Zanoni <paulo.r.zanoni@intel.com>
      Reviewed-by: Jeremy Huddleston Sequoia's avatarJeremy Huddleston <jeremyhu@apple.com>
      d26fae24
    • Paulo Zanoni's avatar
      glx: fix memory leak when destroying screen · 305a8bcb
      Paulo Zanoni authored
      
      
      1,152 bytes in 1 blocks are definitely lost in loss record 536 of 575
         at 0x4C25E84: calloc (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
         by 0x483820: __glXScreenInit (glxscreens.c:357)
         by 0x48271C: __glXDRIscreenProbe (glxdriswrast.c:469)
         by 0x4812BE: GlxExtensionInit (glxext.c:327)
         by 0x41FB14: InitExtensions (miinitext.c:471)
         by 0x5685AE: main (main.c:208)
      Signed-off-by: Paulo Zanoni's avatarPaulo Zanoni <paulo.r.zanoni@intel.com>
      Reviewed-by: Jeremy Huddleston Sequoia's avatarJeremy Huddleston <jeremyhu@apple.com>
      305a8bcb
  6. 23 Nov, 2011 13 commits