mirror of
				https://github.com/libsdl-org/SDL.git
				synced 2025-11-04 01:34:38 +00:00 
			
		
		
		
	Fixed build errors after SDL_IOWhence change
This commit is contained in:
		
				
					committed by
					
						
						Ryan C. Gordon
					
				
			
			
				
	
			
			
			
						parent
						
							9651ca5918
						
					
				
				
					commit
					3e018517c3
				
			@@ -2040,9 +2040,9 @@ Sint64 Android_JNI_FileSize(void *userdata)
 | 
			
		||||
    return (Sint64) AAsset_getLength64((AAsset *)userdata);
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
Sint64 Android_JNI_FileSeek(void *userdata, Sint64 offset, int whence)
 | 
			
		||||
Sint64 Android_JNI_FileSeek(void *userdata, Sint64 offset, SDL_IOWhence whence)
 | 
			
		||||
{
 | 
			
		||||
    return (Sint64) AAsset_seek64((AAsset *)userdata, offset, whence);
 | 
			
		||||
    return (Sint64) AAsset_seek64((AAsset *)userdata, offset, (int)whence);
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
int Android_JNI_FileClose(void *userdata)
 | 
			
		||||
 
 | 
			
		||||
@@ -68,7 +68,7 @@ extern SDL_bool Android_IsChromebook(void);
 | 
			
		||||
 | 
			
		||||
int Android_JNI_FileOpen(void **puserdata, const char *fileName, const char *mode);
 | 
			
		||||
Sint64 Android_JNI_FileSize(void *userdata);
 | 
			
		||||
Sint64 Android_JNI_FileSeek(void *userdata, Sint64 offset, int whence);
 | 
			
		||||
Sint64 Android_JNI_FileSeek(void *userdata, Sint64 offset, SDL_IOWhence whence);
 | 
			
		||||
size_t Android_JNI_FileRead(void *userdata, void *buffer, size_t size, SDL_IOStatus *status);
 | 
			
		||||
size_t Android_JNI_FileWrite(void *userdata, const void *buffer, size_t size, SDL_IOStatus *status);
 | 
			
		||||
int Android_JNI_FileClose(void *userdata);
 | 
			
		||||
 
 | 
			
		||||
@@ -190,7 +190,7 @@ static void testGenericIOStreamValidations(SDL_IOStream *rw, SDL_bool write)
 | 
			
		||||
        (int)i);
 | 
			
		||||
 | 
			
		||||
    /* Invalid whence seek */
 | 
			
		||||
    i = SDL_SeekIO(rw, 0, 999);
 | 
			
		||||
    i = SDL_SeekIO(rw, 0, (SDL_IOWhence)999);
 | 
			
		||||
    SDLTest_AssertPass("Call to SDL_SeekIO(...,0,invalid_whence) succeeded");
 | 
			
		||||
    SDLTest_AssertCheck(
 | 
			
		||||
        i == (Sint64)(-1),
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user