Ticket #272: osx_o_direct.patch

File osx_o_direct.patch, 466 bytes (added by yww4, 11 years ago)

quick fix with #ifdef APPLE

  • lib/ior-stdio.c

     
    6060        if (strcmp(filename,"-") == 0)
    6161                DATA(io)->fd = 0; /* STDIN */
    6262        else
     63#ifdef __APPLE__
     64                DATA(io)->fd = open(filename,O_RDONLY);
     65#else
    6366                DATA(io)->fd = open(filename,O_RDONLY|(force_directio_read?O_DIRECT:0));
     67#endif
    6468        io->source = &stdio_source;
    6569
    6670        if (DATA(io)->fd == -1) {