Index: trunk/glueforge/templates/psdb/alloc.tt
===================================================================
--- trunk/glueforge/templates/psdb/alloc.tt	(revision 5907)
+++ trunk/glueforge/templates/psdb/alloc.tt	(revision 7667)
@@ -22,5 +22,5 @@
 [% FOREACH item = table.columns -%]
 [% IF item.type == "STR" -%]
-    object->[% item.name %] = psStringCopy([% item.name %]);
+    object->[% item.name %] = psMemDecrRefCount(psStringCopy([% item.name %]));
 [% ELSE -%]
     object->[% item.name %] = [% item.name %];
