Method to reproduce:
- Put Factorio on a read-only filesystem
- Keep the config and mods in $HOME/.factorio, as is default.
- Attempt to toggle a mod on or off.
The game will crash, with these messages:
Code: Select all
15.691 Info AppManager.cpp:643: Restarting Factorio
15.692 Error Util.cpp:57: boost::filesystem::permissions: Read-only file system: "/home/svein/factorio/result/bin/factorio"
===
This is problematic, because for me that file is a NixOS-generated wrapper (full contents below), and since Factorio re-executes itself with all its parameters instact this is both pointless and -- because it doubles up on the -c parameter -- going to crash. It should re-execute argv[0], rather than assume that its executable is named factorio.
Code: Select all
#! /nix/store/x9z39620crc9d5lbrcsqzzsiifnsszql-bash-4.3-p46/bin/bash -e
export LD_LIBRARY_PATH=/run/opengl-driver/lib:/nix/store/2px33m9kzfy03kzfwanknfacnjn0cz9c-alsa-lib-1.1.1/lib:/nix/store/gz37rmvr8mbgnfsbgb35ggvrlpb81zcd-libX11-1.6.3/lib:/nix/store/py4v4ibh2953bh2k1ra7bqk4c229c7j0-libXcursor-1.1.14/lib:/nix/store/qkf6ahn5whib5kq141nv12nvibjny0p1-libXinerama-1.1.3/lib:/nix/store/f8x3jjqra8mx9xcyfh2qlsh7yjy3fn7c-libXrandr-1.5.0/lib:/nix/store/0k6jvngwvhk8fi7x7gw6xlgmgnnb7ys8-libXi-1.7.6/lib:/nix/store/vanw7c5srnzpj1l4jc5p3fm6b82al3xi-mesa-noglu-12.0.1/lib${LD_LIBRARY_PATH:+:}$LD_LIBRARY_PATH
/nix/store/fmccn00a6h2f9qr4fsnyyai24dgsmyqv-factorio-alpha-0.13.13/share/factorio/update-config.sh
exec -a "$0" /nix/store/fmccn00a6h2f9qr4fsnyyai24dgsmyqv-factorio-alpha-0.13.13/bin/.factorio-wrapped -c $HOME/.factorio/config.cfg "${extraFlagsArray[@]}" "$@"