Welcome to Emulationworld

Forum Index | FAQ | New User | Login | Search

*View All Threads*Show in Threaded Mode


SubjectMAME 125u4 -listxml crash + fix new Reply to this message
Posted byRoman
Posted on06/05/08 01:29 PM



you need to apply the following to get it work:

Index: src/emu/inptport.c
===================================================================
--- src/emu/inptport.c (revision 1818)
+++ src/emu/inptport.c (working copy)
@@ -731,6 +731,8 @@

const input_port_config *input_port_config_alloc(const input_port_token *tokens, char *errorbuf, int errorbuflen)
{
+ if (tokens == NULL)
+ return NULL;
if (errorbuf != NULL)
*errorbuf = 0;
return port_config_detokenize(NULL, tokens, errorbuf, errorbuflen);



thanks to Aaron for the quick reply


Roman Scherzer



SubjectRe: MAME 125u4 -listxml crash + fix new Reply to this message
Posted byuTaR
Posted on06/05/08 05:01 PM



> you need to apply the following to get it work:
>
> Index: src/emu/inptport.c
> ===================================================================
> --- src/emu/inptport.c (revision 1818)
> +++ src/emu/inptport.c (working copy)
> @@ -731,6 +731,8 @@
>
> const input_port_config *input_port_config_alloc(const input_port_token
> *tokens, char *errorbuf, int errorbuflen)
> {
> + if (tokens == NULL)
> + return NULL;
> if (errorbuf != NULL)
> *errorbuf = 0;
> return port_config_detokenize(NULL, tokens, errorbuf, errorbuflen);
>
>
>
> thanks to Aaron for the quick reply
>
>
> Roman Scherzer
>

Hi


How do I apply this?

I've tried copying the above into a file but the usual:

patch -p0 -E [left facing pointy bracket]filename.diff

[note the left facing pointy bracket isn't displaying for some reason on this forum, perhaps this is the problem with the code above?]

Gives an error message, on the line starting with "const"


Utar




SubjectRe: MAME 125u4 -listxml crash + fix new Reply to this message
Posted byRoman
Posted on06/05/08 05:04 PM



> Gives an error message, on the line starting with "const"

Don't copy/paste from the forum. It will trash the needed formatting breaks. So either save it correctly or simply add the "if" manually.


Roman Scherzer



SubjectRe: MAME 125u4 -listxml crash + fix new Reply to this message
Posted byuTaR
Posted on06/05/08 05:19 PM




Thanks for the quick reply.

Call me stupid (me waits for insult!) but other then copying and pasting it I'm not sure how else to save the code.


Utar




SubjectRe: MAME 125u4 -listxml crash + fix new Reply to this message
Posted byRoman
Posted on06/05/08 05:22 PM



grab it here
http://www.mameworld.info/ubbthreads/showthreaded.php?Cat=&Number=153490&page=0&view=expanded&sb=5&o=&fpart=1&vc=1


Roman Scherzer



SubjectRe: MAME 125u4 -listxml crash + fix Reply to this message
Posted byuTaR
Posted on06/05/08 05:42 PM



> grab it here
http://www.mameworld.info/ubbthrea> ds/showthreaded.php?Cat=&Number=153490&page=0&view=expanded&sb=5&o=&fpart=1&vc=1
>

Thanks, that worked great.






View All Threads*Show in Threaded Mode