+ try to fix the problem with corrupted resources on arm kiwix-serve

This commit is contained in:
kelson42 committed 2012-05-20 10:53:00 +00:00
1 parent f29a845682
commit 2cd537fd02
4 files changed
+17 -18

No files matched your search

+2 -2
View File
@@ -2,9 +2,9 @@
#include <iostream>
std::string getResourceAsString(const std::string &name) {
std::map<std::string, const char*>::iterator it = resourceMap.find(name);
std::map<std::string, std::pair<const unsigned char*, unsigned int> >::iterator it = resourceMap.find(name);
if (it != resourceMap.end()) {
return std::string(strdup(resourceMap[name]));
return std::string(strdup((const char*)resourceMap[name].first), resourceMap[name].second);
}
return "";
}