Skip to content

Commit b2bfd09

Browse files
authored
fix mcman detection of unformatted card insertion
Before this change, every time mcdetectcard was called from libmc over an unformatted card, the mcsync return value was -2 It should have been -2 if a new unformatted card was inserted since las call, and 0 if the same card remains plugged
1 parent ba63930 commit b2bfd09

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

iop/memorycard/mcman/src/mcsio2.c

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -917,7 +917,10 @@ int mcman_probePS2Card(int port, int slot) //2
917917
SecrAuthDongle(2, slot, mcman_getcnum(port, slot));
918918
}
919919
#endif
920-
if (r > 0)
920+
HAKAMA_SIGNALSEMA();
921+
if (r != 0)
922+
return 0;
923+
/*if (r > 0)
921924
{
922925
DPRINTF("mcman_probePS2Card sio2cmd succeeded\n");
923926
HAKAMA_SIGNALSEMA();
@@ -928,7 +931,7 @@ int mcman_probePS2Card(int port, int slot) //2
928931
DPRINTF("mcman_probePS2Card sio2cmd failed (no format)\n");
929932
HAKAMA_SIGNALSEMA();
930933
return sceMcResNoFormat;
931-
}
934+
}*/
932935
}
933936

934937
#if !defined(BUILDING_XFROMMAN) && !defined(BUILDING_VMCMAN)

0 commit comments

Comments
 (0)