Closed Bug 1189738 Opened 10 years ago Closed 10 years ago

Port Bug 1189156 [Don't use enumeration style in hash table SizeOf*() functions ] to comm-central

Categories

(SeaMonkey :: MailNews: General, defect)

x86_64
Linux
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED DUPLICATE of bug 1189736

People

(Reporter: misak.bugzilla, Assigned: misak.bugzilla)

References

Details

Trying to fix this, but can't understand first part of patch. I don't have deep knowledge in this par of code and generally in programming. Nicolas, can You please suggest the correct way? Currently patch doesn't compile with this error: 0:05.35 /home/misak/workspace/src/mailnews/db/msgdb/src/nsMsgDatabase.cpp: In member function ‘virtual size_t nsMsgDatabase::SizeOfExcludingThis(mozilla::MallocSizeOf) const’: 0:05.35 /home/misak/workspace/src/mailnews/db/msgdb/src/nsMsgDatabase.cpp:1004:56: error: request for member ‘ConstIter’ in ‘nsMsgDatabase::HeaderHashSizeOf’, which is of non-class type ‘size_t(PLDHashEntryHdr*, mozilla::MallocSizeOf, void*) {aka long unsigned int(PLDHashEntryHdr*, long unsigned int (*)(const void*), void*)}’ 0:05.35 for (auto iter = nsMsgDatabase::HeaderHashSizeOf.ConstIter(); !iter.Done(); iter.Next()) { 0:05.35 ^ 0:05.35 /home/misak/workspace/src/mailnews/db/msgdb/src/nsMsgDatabase.cpp:1005:34: error: ‘GlobalNameMapEntry’ does not name a type 0:05.35 auto entry = static_cast<GlobalNameMapEntry*>(iter.Get()); 0:05.35 ^ 0:05.35 /home/misak/workspace/src/mailnews/db/msgdb/src/nsMsgDatabase.cpp:1005:52: error: expected ‘>’ before ‘*’ token 0:05.35 auto entry = static_cast<GlobalNameMapEntry*>(iter.Get()); 0:05.35 ^ 0:05.35 /home/misak/workspace/src/mailnews/db/msgdb/src/nsMsgDatabase.cpp:1005:52: error: expected ‘(’ before ‘*’ token 0:05.35 /home/misak/workspace/src/mailnews/db/msgdb/src/nsMsgDatabase.cpp:1005:53: error: expected primary-expression before ‘>’ token 0:05.35 auto entry = static_cast<GlobalNameMapEntry*>(iter.Get()); 0:05.35 ^ 0:05.35 /home/misak/workspace/src/mailnews/db/msgdb/src/nsMsgDatabase.cpp:1005:66: error: expected ‘)’ before ‘;’ token 0:05.35 auto entry = static_cast<GlobalNameMapEntry*>(iter.Get()); 0:05.35 ^ 0:05.35 /home/misak/workspace/src/mailnews/db/msgdb/src/nsMsgDatabase.cpp: In member function ‘virtual nsresult nsMsgDatabase::GetCachedHits(const char*, nsISimpleEnumerator**)’: 0:05.35 Warning: -Wunused-variable in /home/misak/workspace/src/mailnews/db/msgdb/src/nsMsgDatabase.cpp: unused variable ‘err’ 0:05.35 /home/misak/workspace/src/mailnews/db/msgdb/src/nsMsgDatabase.cpp:5714:12: warning: unused variable ‘err’ [-Wunused-variable] 0:05.35 nsresult err = GetSearchResultsTable(aSearchFolderUri, false, getter_AddRefs(table)); 0:05.35 ^ 0:05.35 0:05.35 In the directory /home/misak/workspace/suite-opt/mailnews/db/msgdb/src 0:05.35 The following command failed to execute properly: 0:05.35 /usr/bin/ccache c++ -o nsMsgDatabase.o -c -I../../../../dist/stl_wrappers -I../../../../dist/system_wrappers -include /home/misak/workspace/src/mozilla/config/gcc_hidden.h -DSTATIC_EXPORTABLE_JS_API -DMOZILLA_INTERNAL_API -DIMPL_LIBXUL -DAB_CD=en-US -DNO_NSPR_10_SUPPORT -I/home/misak/workspace/src/mailnews/db/msgdb/src -I. -I../../../../dist/include -I/home/misak/workspace/suite-opt/dist/include/nspr -I/home/misak/workspace/suite-opt/dist/include/nss -fPIC -DMOZILLA_CLIENT -include ../../../../mozilla-config.h -MD -MP -MF .deps/nsMsgDatabase.o.pp -Wall -Wempty-body -Woverloaded-virtual -Wsign-compare -Wwrite-strings -Wno-invalid-offsetof -Wcast-align -fno-exceptions -fno-strict-aliasing -fno-rtti -ffunction-sections -fdata-sections -fno-exceptions -fno-math-errno -std=gnu++0x -pthread -pipe -DNDEBUG -DTRIMMED -freorder-blocks -Os -fomit-frame-pointer /home/misak/workspace/src/mailnews/db/msgdb/src/nsMsgDatabase.cpp 0:05.35 /home/misak/workspace/src/mozilla/config/rules.mk:958: recipe for target 'nsMsgDatabase.o' failed 0:05.35 gmake[4]: *** [nsMsgDatabase.o] Error 1 0:05.35 /home/misak/workspace/src/mozilla/config/recurse.mk:71: recipe for target 'mailnews/db/msgdb/src/target' failed 0:05.35 gmake[3]: *** [mailnews/db/msgdb/src/target] Error 2 0:05.35 /home/misak/workspace/src/mozilla/config/recurse.mk:32: recipe for target 'compile' failed 0:05.35 gmake[2]: *** [compile] Error 2 0:05.35 /home/misak/workspace/src/mozilla/config/rules.mk:549: recipe for target 'default' failed 0:05.35 gmake[1]: *** [default] Error 2 0:05.35 client.mk:404: recipe for target 'build' failed 0:05.35 gmake: *** [build] Error 2 0:05.40 856 compiler warnings present. 0:06.47 ccache (direct) hit rate: 0.0%; (preprocessed) hit rate: 0.0%; miss rate: 100.0%
Assignee: nobody → misak.bugzilla
Flags: needinfo?(n.nethercote)
Status: NEW → RESOLVED
Closed: 10 years ago
Resolution: --- → DUPLICATE
Flags: needinfo?(n.nethercote)
You need to log in before you can comment on or make changes to this bug.