Viewing Issue Advanced Details
ID Category [?] Severity [?] Reproducibility Date Submitted Last Update
03437 Interface Feature Always Sep 12, 2009, 17:04 Jul 21, 2017, 08:27
Tester Tafoid View Status Public Platform MAME (Official Binary)
Assigned To Resolution Fixed OS
Status [?] Resolved Driver
Version 0.134 Fixed in Version Build
Fixed in Git Commit Github Pull Request #
Summary 03437: -mngwrite does not allow absolute path
Description This command does not allow use of absolute paths in the command line.

mame mappy -mngwrite c:\mappy.mng

This results currently in an Access Violation. The crash shows:
Program received signal SIGSEGV, Segmentation fault.
0x00b4b5aa in mame_core_file (file=0x0) at src/emu/fileio.c:753
753     src/emu/fileio.c: No such file or directory.
        in src/emu/fileio.c

This specific regression started in 0.125u6, when new snapshot functionality was added. The core problem lies even earlier, though, way back to 0.106u3. The above command works as expected in 0.106u2 or earlier. In 0.106u3, the complete -MNGWRITE command is ignored and is never written.

By contrast, this command has always worked throughout:
mame mappy -wavwrite c:\mappy.wav
Steps To Reproduce
Additional Information
Github Commit
Regression Version 0.106u3, 0.125u6
Affected Sets / Systems
Attached Files
There are no relationship linked to this issue.
User avatar
Sep 15, 2009, 19:55
I think this happens by design. mngwrite and aviwrite are supposed to save their output to the snap directory not to a general directory. wavwrite it is supposed to save to whatever location the user wishes (the same directory as the emu by default)

we can call it a feature request (to be consistent among these output options), but I don't think it is a bug.
of course, we can also debate about how effective is the current description of those options in the docs ;)
User avatar
Sep 15, 2009, 20:09
maybe so, but the crash would still be a bug
Sep 16, 2009, 06:45
Changing this line in the emu/video.c fix the problem, but I don't know is the correct fix

- filerr = mame_fopen(SEARCHPATH_MOVIE, name, OPEN_FLAG_WRITE | OPEN_FLAG_CREATE | OPEN_FLAG_CREATE_PATHS, &global.mngfile);
+ filerr = mame_fopen((strchr(name, '\\') || strchr(name, '/')) ? NULL : SEARCHPATH_MOVIE, name, OPEN_FLAG_WRITE | OPEN_FLAG_CREATE | OPEN_FLAG_CREATE_PATHS, &global.mngfile);
User avatar
Sep 23, 2009, 00:08
It will be nice to have this available, I use mame in a external 320Gb USB HDD. In my home computer I have much more space and power to record games with aviwrite, be able to give an output path make our lives more easy.
User avatar
Jul 21, 2017, 08:27
This does not crash anymore: the game runs, but no file is written and you get the following output:
Error creating MNG, osd_file::error=3