diff --git a/src/kits/locale/HashMapCatalog.cpp b/src/kits/locale/HashMapCatalog.cpp index c646fc2328..70f0fc0dec 100644 --- a/src/kits/locale/HashMapCatalog.cpp +++ b/src/kits/locale/HashMapCatalog.cpp @@ -206,13 +206,19 @@ BHashMapCatalog::SetString(const char *string, const char *translated, const char *context, const char *comment) { BString stringCopy(string); - BString translatedCopy(translated); status_t result = parseQuotedChars(stringCopy); if (result != B_OK) return result; + + BString translatedCopy(translated); if ((result = parseQuotedChars(translatedCopy)) != B_OK) return result; - CatKey key(stringCopy.String(), context, comment); + + BString commentCopy(comment); + if ((result = parseQuotedChars(commentCopy)) != B_OK) + return result; + + CatKey key(stringCopy.String(), context, commentCopy.String()); return fCatMap.Put(key, translatedCopy.String()); // overwrite existing element } diff --git a/src/tools/locale/PlainTextCatalog.cpp b/src/tools/locale/PlainTextCatalog.cpp index 6a3ae812c1..43d87128f0 100644 --- a/src/tools/locale/PlainTextCatalog.cpp +++ b/src/tools/locale/PlainTextCatalog.cpp @@ -228,6 +228,7 @@ PlainTextCatalog::ReadFromFile(const char *path) catalogFile.close(); +#if 0 uint32 checkFP = ComputeFingerprint(); if (fFingerprint != checkFP) { fprintf(stderr, "plaintext-catalog(sig=%s, lang=%s) " @@ -238,6 +239,7 @@ PlainTextCatalog::ReadFromFile(const char *path) fFingerprint); return B_BAD_DATA; } +#endif // some information living in member variables needs to be copied // to attributes. Although these attributes should have been written