test/automated/rwops/TestSupportRWops_Generic.c
author Sam Lantinga <slouken@libsdl.org>
Thu, 20 Jan 2011 18:04:05 -0800
changeset 5062 e8916fe9cfc8
parent 4884 27ab20a36eba
child 7191 75360622e65f
permissions -rw-r--r--
Fixed bug #925

Changed "win32" to "windows"
     1 /* Generic implementation for file opening routines.
     2 * Customizations for specific platforms should go in alternative files.
     3 */
     4 
     5 // quiet windows compiler warnings
     6 #define _CRT_SECURE_NO_WARNINGS
     7 
     8 #include <stdio.h>
     9 #include "SDL.h"
    10 
    11 const char* RWOPS_READ = "rwops/read";
    12 const char* RWOPS_WRITE = "rwops/write";
    13 
    14 FILE* TestSupportRWops_OpenFPFromReadDir(const char *file, const char *mode)
    15 {
    16 	return fopen(file, mode);
    17 }
    18 
    19 FILE* TestSupportRWops_OpenFPFromWriteDir(const char *file, const char *mode)
    20 {
    21 	return fopen(file, mode);
    22 }
    23 
    24 SDL_RWops* TestSupportRWops_OpenRWopsFromReadDir(const char *file, const char *mode)
    25 {
    26 	return SDL_RWFromFile(file, mode);
    27 }
    28 
    29 SDL_RWops* TestSupportRWops_OpenRWopsFromWriteDir(const char *file, const char *mode)
    30 {
    31 	return SDL_RWFromFile(file, mode);
    32 }