this cannot be correct. filename is a char* so it has to be SG_FREE() but then again it seems like the issue should rather be fixed in SerializableFile.