diff options
Diffstat (limited to 'rbutil/sansapatcher/sansaio-win32.c')
-rw-r--r-- | rbutil/sansapatcher/sansaio-win32.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/rbutil/sansapatcher/sansaio-win32.c b/rbutil/sansapatcher/sansaio-win32.c index 8c2c696c1a..15bf82be3c 100644 --- a/rbutil/sansapatcher/sansaio-win32.c +++ b/rbutil/sansapatcher/sansaio-win32.c @@ -79,7 +79,10 @@ int sansa_open(struct sansa_t* sansa, int silent) if (sansa->dh == INVALID_HANDLE_VALUE) { if (!silent) print_error(" Error opening disk: "); - return -1; + if(GetLastError() == ERROR_ACCESS_DENIED) + return -2; + else + return -1; } if (!lock_volume(sansa->dh)) { |