Ticket #3596: wxGTK-2.4.2-gcc4

File wxGTK-2.4.2-gcc4, 10.8 KB (added by benwill@…, 19 years ago)

patch to go with above

Line 
1diff -r -u contrib/src/stc/scintilla/include/KeyWords.h contrib/src/stc/scintilla/include/KeyWords.h
2--- contrib/src/stc/scintilla/include/KeyWords.h        2003-09-21 04:32:47.000000000 -0700
3+++ contrib/src/stc/scintilla/include/KeyWords.h        2005-06-17 14:25:25.000000000 -0700
4@@ -29,6 +29,7 @@
5        LexerModule(int language_, LexerFunction fnLexer_,
6                const char *languageName_=0, LexerFunction fnFolder_=0,
7                const char * const wordListDescriptions_[] = NULL);
8+       virtual ~LexerModule() {};
9        int GetLanguage() const { return language; }
10 
11        // -1 is returned if no WordList information is available
12diff -r -u contrib/src/stc/scintilla/src/Document.cxx contrib/src/stc/scintilla/src/Document.cxx
13--- contrib/src/stc/scintilla/src/Document.cxx  2003-09-21 04:32:47.000000000 -0700
14+++ contrib/src/stc/scintilla/src/Document.cxx  2005-06-17 14:25:25.000000000 -0700
15@@ -850,6 +850,7 @@
16        DocumentIndexer(Document *pdoc_, int end_) :
17                pdoc(pdoc_), end(end_) {
18        }
19+       virtual ~DocumentIndexer() {};
20 
21        virtual char CharAt(int index) {
22                if (index < 0 || index >= end)
23diff -r -u contrib/src/stc/scintilla/src/ExternalLexer.h contrib/src/stc/scintilla/src/ExternalLexer.h
24--- contrib/src/stc/scintilla/src/ExternalLexer.h       2003-09-21 04:32:50.000000000 -0700
25+++ contrib/src/stc/scintilla/src/ExternalLexer.h       2005-06-17 14:25:25.000000000 -0700
26@@ -38,6 +38,7 @@
27                strncpy(name, languageName_, sizeof(name));
28                languageName = name;
29        };
30+       virtual ~ExternalLexerModule() {};
31        virtual void Lex(unsigned int startPos, int lengthDoc, int initStyle,
32                                        WordList *keywordlists[], Accessor &styler) const;
33        virtual void Fold(unsigned int startPos, int lengthDoc, int initStyle,
34diff -r -u contrib/src/stc/scintilla/src/RESearch.h contrib/src/stc/scintilla/src/RESearch.h
35--- contrib/src/stc/scintilla/src/RESearch.h    2003-09-21 04:32:50.000000000 -0700
36+++ contrib/src/stc/scintilla/src/RESearch.h    2005-06-17 14:25:25.000000000 -0700
37@@ -20,6 +20,7 @@
38 class CharacterIndexer {
39 public:
40        virtual char CharAt(int index)=0;
41+       virtual ~CharacterIndexer() {};
42 };
43 
44 class RESearch {
45diff -r -u contrib/src/xrc/expat/xmlparse/xmlparse.c contrib/src/xrc/expat/xmlparse/xmlparse.c
46--- contrib/src/xrc/expat/xmlparse/xmlparse.c   2003-09-21 04:32:54.000000000 -0700
47+++ contrib/src/xrc/expat/xmlparse/xmlparse.c   2005-06-17 14:25:25.000000000 -0700
48@@ -203,8 +203,10 @@
49 static enum XML_Error
50 doProlog(XML_Parser parser, const ENCODING *enc, const char *s,
51         const char *end, int tok, const char *next, const char **nextPtr);
52+#ifdef XML_DTD
53 static enum XML_Error
54 processInternalParamEntity(XML_Parser parser, ENTITY *entity);
55+#endif /* XML_DTD */
56 static enum XML_Error
57 doContent(XML_Parser parser, int startTagLevel, const ENCODING *enc,
58          const char *start, const char *end, const char **endPtr);
59diff -r -u contrib/src/xrc/xml.cpp contrib/src/xrc/xml.cpp
60--- contrib/src/xrc/xml.cpp     2003-09-21 04:32:56.000000000 -0700
61+++ contrib/src/xrc/xml.cpp     2005-06-17 14:25:25.000000000 -0700
62@@ -354,8 +354,8 @@
63 #else
64     if ( conv )
65     {
66-        size_t nLen = (len != wxSTRING_MAXLEN) ? len :
67-                          nLen = wxConvUTF8.MB2WC((wchar_t*) NULL, s, 0);
68+        size_t nLen = ((len != wxSTRING_MAXLEN) ? len :
69+                          wxConvUTF8.MB2WC((wchar_t*) NULL, s, 0));
70 
71         wchar_t *buf = new wchar_t[nLen+1];
72         wxConvUTF8.MB2WC(buf, s, nLen);
73diff -r -u include/wx/caret.h include/wx/caret.h
74--- include/wx/caret.h  2003-09-21 04:31:30.000000000 -0700
75+++ include/wx/caret.h  2005-06-17 14:25:25.000000000 -0700
76@@ -60,6 +60,7 @@
77 
78         (void)Create(window, size);
79     }
80+    virtual ~wxCaretBase() {};
81 
82     // Create() functions - same as ctor but returns the success code
83     // --------------------------------------------------------------
84diff -r -u include/wx/clipbrd.h include/wx/clipbrd.h
85--- include/wx/clipbrd.h        2003-09-21 04:31:30.000000000 -0700
86+++ include/wx/clipbrd.h        2005-06-17 14:25:25.000000000 -0700
87@@ -39,6 +39,7 @@
88 {
89 public:
90     wxClipboardBase();
91+    virtual ~wxClipboardBase() {};
92 
93     // open the clipboard before Add/SetData() and GetData()
94     virtual bool Open() = 0;
95diff -r -u include/wx/datetime.h include/wx/datetime.h
96--- include/wx/datetime.h       2003-09-21 04:31:30.000000000 -0700
97+++ include/wx/datetime.h       2005-06-17 14:25:25.000000000 -0700
98@@ -1300,6 +1300,7 @@
99 {
100 friend class wxDateTimeHolidaysModule;
101 public:
102+    virtual ~wxDateTimeHolidayAuthority() {};
103     // returns TRUE if the given date is a holiday
104     static bool IsHoliday(const wxDateTime& dt);
105 
106@@ -1340,6 +1341,8 @@
107 // the holidays for this class are all Saturdays and Sundays
108 class WXDLLEXPORT wxDateTimeWorkDays : public wxDateTimeHolidayAuthority
109 {
110+public:
111+    virtual ~wxDateTimeWorkDays() {};
112 protected:
113     virtual bool DoIsHoliday(const wxDateTime& dt) const;
114     virtual size_t DoGetHolidaysInRange(const wxDateTime& dtStart,
115diff -r -u include/wx/dir.h include/wx/dir.h
116--- include/wx/dir.h    2003-09-21 04:31:32.000000000 -0700
117+++ include/wx/dir.h    2005-06-17 14:25:26.000000000 -0700
118@@ -52,6 +52,7 @@
119 class WXDLLEXPORT wxDirTraverser
120 {
121 public:
122+    virtual ~wxDirTraverser() {};
123     // called for each file found by wxDir::Traverse()
124     //
125     // return wxDIR_STOP or wxDIR_CONTINUE from here
126diff -r -u include/wx/event.h include/wx/event.h
127--- include/wx/event.h  2003-09-21 04:31:33.000000000 -0700
128+++ include/wx/event.h  2005-06-17 14:25:26.000000000 -0700
129@@ -1952,6 +1952,7 @@
130         : wxEventTableEntryBase(id, idLast, fn, data),
131         m_eventType(evType)
132     { }
133+    virtual ~wxEventTableEntry() {};
134 
135     // the reference to event type: this allows us to not care about the
136     // (undefined) order in which the event table entries and the event types
137diff -r -u include/wx/geometry.h include/wx/geometry.h
138--- include/wx/geometry.h       2003-09-21 04:31:34.000000000 -0700
139+++ include/wx/geometry.h       2005-06-17 14:25:26.000000000 -0700
140@@ -785,6 +785,7 @@
141 class wxTransform2D
142 {
143 public :
144+    virtual ~wxTransform2D() {};
145     virtual void                    Transform( wxPoint2DInt* pt )const  = 0;
146     virtual void                    Transform( wxRect2DInt* r ) const;
147     virtual wxPoint2DInt    Transform( const wxPoint2DInt &pt ) const;
148diff -r -u include/wx/list.h include/wx/list.h
149--- include/wx/list.h   2003-09-21 04:31:34.000000000 -0700
150+++ include/wx/list.h   2005-06-17 14:25:26.000000000 -0700
151@@ -384,6 +384,7 @@
152                  T *data = (T *)NULL,                                       \
153                  const wxListKey& key = wxDefaultListKey)                   \
154             : wxNodeBase(list, previous, next, data, key) { }               \
155+        virtual ~nodetype() {};                                             \
156                                                                             \
157         nodetype *GetNext() const                                           \
158             { return (nodetype *)wxNodeBase::GetNext(); }                   \
159@@ -410,6 +411,7 @@
160                                                                             \
161         name& operator=(const name& list)                                   \
162             { (void) wxListBase::operator=(list); return *this; }           \
163+        virtual ~name() {};                                                 \
164                                                                             \
165         nodetype *GetFirst() const                                          \
166             { return (nodetype *)wxListBase::GetFirst(); }                  \
167diff -r -u include/wx/notebook.h include/wx/notebook.h
168--- include/wx/notebook.h       2003-09-21 04:31:34.000000000 -0700
169+++ include/wx/notebook.h       2005-06-17 14:25:26.000000000 -0700
170@@ -193,6 +193,7 @@
171             m_nSel = nSel;
172             m_nOldSel = nOldSel;
173         }
174+    virtual ~wxNotebookEvent() {};
175 
176     // accessors
177         // the currently selected page (-1 if none)
178diff -r -u include/wx/radiobox.h include/wx/radiobox.h
179--- include/wx/radiobox.h       2003-09-21 04:31:35.000000000 -0700
180+++ include/wx/radiobox.h       2005-06-17 14:25:26.000000000 -0700
181@@ -35,6 +35,7 @@
182 class WXDLLEXPORT wxRadioBoxBase
183 {
184 public:
185+    virtual ~wxRadioBoxBase() {};
186     // selection
187     virtual void SetSelection(int n) = 0;
188     virtual int GetSelection() const = 0;
189diff -r -u include/wx/statline.h include/wx/statline.h
190--- include/wx/statline.h       2003-09-21 04:31:35.000000000 -0700
191+++ include/wx/statline.h       2005-06-17 14:25:26.000000000 -0700
192@@ -39,6 +39,7 @@
193 public:
194     // constructor
195     wxStaticLineBase() { }
196+    virtual ~wxStaticLineBase() {};
197 
198     // is the line vertical?
199     bool IsVertical() const { return (GetWindowStyle() & wxLI_VERTICAL) != 0; }
200diff -r -u src/common/dircmn.cpp src/common/dircmn.cpp
201--- src/common/dircmn.cpp       2003-09-21 04:31:39.000000000 -0700
202+++ src/common/dircmn.cpp       2005-06-17 14:25:26.000000000 -0700
203@@ -147,6 +147,7 @@
204 {
205 public:
206     wxDirTraverserSimple(wxArrayString& files) : m_files(files) { }
207+    virtual ~wxDirTraverserSimple() {};
208 
209     virtual wxDirTraverseResult OnFile(const wxString& filename)
210     {
211diff -r -u src/common/dynlib.cpp src/common/dynlib.cpp
212--- src/common/dynlib.cpp       2003-09-21 04:31:39.000000000 -0700
213+++ src/common/dynlib.cpp       2005-06-17 14:26:33.000000000 -0700
214@@ -478,7 +478,7 @@
215     return handle;
216 }
217 
218-int dlclose(void *handle)
219+int dlclose(__NSModule *handle)
220 {
221     NSUnLinkModule( handle, NSUNLINKMODULE_OPTION_NONE);
222     return 0;
223Only in src/common: dynlib.cpp~
224diff -r -u src/common/sckfile.cpp src/common/sckfile.cpp
225--- src/common/sckfile.cpp      2003-09-21 04:31:39.000000000 -0700
226+++ src/common/sckfile.cpp      2005-06-17 14:25:26.000000000 -0700
227@@ -9,7 +9,7 @@
228 // Licence:     wxWindows license
229 /////////////////////////////////////////////////////////////////////////////
230 #ifdef __GNUG__
231-#pragma implementation "sckfile.h"
232+#pragma implementation "file.h"
233 #endif
234 
235 // For compilers that support precompilation, includes "wx.h".
236diff -r -u src/common/xpmdecod.cpp src/common/xpmdecod.cpp
237--- src/common/xpmdecod.cpp     2003-09-21 04:31:39.000000000 -0700
238+++ src/common/xpmdecod.cpp     2005-06-17 14:25:26.000000000 -0700
239@@ -669,7 +669,7 @@
240     wxChar key[64];
241     const char *clr_def;
242     bool hasMask;
243-    wxXPMColourMapData clr_data;
244+    wxXPMColourMapData clr_data = {0, 0, 0};
245     wxXPMColourMap clr_tbl;
246 
247     /*
248@@ -712,7 +712,7 @@
249         }
250         else
251         {
252-            bool isNone;
253+            bool isNone = false;
254             if ( !GetRGBFromName(clr_def, &isNone,
255                                  &clr_data.R, &clr_data.G, &clr_data.B) )
256             {
257diff -r -u src/unix/mimetype.cpp src/unix/mimetype.cpp
258--- src/unix/mimetype.cpp       2003-09-21 04:31:40.000000000 -0700
259+++ src/unix/mimetype.cpp       2005-06-17 14:25:26.000000000 -0700
260@@ -1580,7 +1580,7 @@
261     {
262         // now got a file we can write to ....
263         wxMimeTypeCommands * entries = m_aEntries[index];
264-        size_t iOpen;
265+        size_t iOpen = 0;
266         wxString sCmd = entries->GetCommandForVerb(_T("open"), &iOpen);
267         wxString sTmp;
268