Use const return values for string cache

This is a prerequisite for being able to return "" (which is const) and
none of the returned values should ever be modified.
This commit is contained in:
Simon Arlott
2021-07-08 20:42:03 +01:00
parent e1c153a516
commit 320df7e409
29 changed files with 152 additions and 195 deletions

View File

@@ -613,7 +613,7 @@ qof_book_get_collection (const QofBook *book, QofIdType entity_type)
col = qof_collection_new (entity_type);
g_hash_table_insert(
book->hash_of_collections,
qof_string_cache_insert(entity_type), col);
(gpointer)qof_string_cache_insert(entity_type), col);
}
return col;
}