I don't know whether the current issue is related to that, but writing to the ini file depends on a setting in mess.ini that explicitly enables this (writeconfig).
I remember well the headache introduced with writing the selected cartridges to a persistent configuration. This makes sense for half of the systems, and for the other half it's just a pain in the backside. Especially when you want to use mess from the command line and somehow have to get rid of that crashing autostart cartridge from last session.