some fixups to the plugin_mem plugin