Followup to bug 571728 - catch the remaining places where the return value of get_current_cs is freed; r=Olli.Pettay
authorEhsan Akhgari <ehsan@mozilla.com>
Sun, 13 Jun 2010 22:48:24 -0400
changeset 43876 211153ce7d8478cca7505e8020cb52ac81b189e0
parent 43875 671d4c09f4ad72a63f2d97e124dd08cf5d557908
child 43877 e92012b73cbba7bbc5952fec3e7c23487cbec07d
push idunknown
push userunknown
push dateunknown
reviewersOlli.Pettay
bugs571728
milestone1.9.3a6pre
Followup to bug 571728 - catch the remaining places where the return value of get_current_cs is freed; r=Olli.Pettay
extensions/spellcheck/hunspell/src/affixmgr.cpp
extensions/spellcheck/hunspell/src/hunspell.cpp
--- a/extensions/spellcheck/hunspell/src/affixmgr.cpp
+++ b/extensions/spellcheck/hunspell/src/affixmgr.cpp
@@ -63,16 +63,20 @@
 #include <vector>
 
 #include "affixmgr.hxx"
 #include "affentry.hxx"
 #include "langnum.hxx"
 
 #include "csutil.hxx"
 
+#ifdef MOZILLA_CLIENT
+#include "nscore.h" // for mozalloc headers
+#endif
+
 AffixMgr::AffixMgr(const char * affpath, HashMgr** ptr, int * md, const char * key) 
 {
   // register hash manager and load affix data from aff file
   pHMgr = ptr[0];
   alldic = ptr;
   maxdic = md;
   keystring = NULL;
   trystring = NULL;
--- a/extensions/spellcheck/hunspell/src/hunspell.cpp
+++ b/extensions/spellcheck/hunspell/src/hunspell.cpp
@@ -56,17 +56,19 @@
  ******* END LICENSE BLOCK *******/
 
 #include <stdlib.h>
 #include <string.h>
 #include <stdio.h>
 
 #include "hunspell.hxx"
 #include "hunspell.h"
-#ifndef MOZILLA_CLIENT
+#ifdef MOZILLA_CLIENT
+#    include "nscore.h"
+#else
 #    include "config.h"
 #endif
 #include "csutil.hxx"
 
 Hunspell::Hunspell(const char * affpath, const char * dpath, const char * key)
 {
     encoding = NULL;
     csconv = NULL;