Ignore:
Timestamp:
04/25/06 21:26:03 (15 years ago)
Author:
Perry Lorier <perry@…>
Branches:
4.0.1-hotfixes, cachetimestamps, develop, dpdk-ndag, etsilive, getfragoff, help, libtrace4, master, ndag_format, pfring, rc-4.0.1, rc-4.0.2, rc-4.0.3, rc-4.0.4, ringdecrementfix, ringperformance, ringtimestampfixes
Children:
e4ebf84
Parents:
7fc01569
Message:

add O_BINARY to keep windows happy.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • lib/format_helper.c

    r8bef018 rb874684  
    154154#endif
    155155
     156/* Catching O_BINARY on all sane OS's */
     157#ifndef O_BINARY
     158#  define O_BINARY 0
     159#endif
     160
    156161/* open a file or stdin using gzip compression if necessary (and supported)
    157162 * @internal
     
    171176         * as zlib doesn't always do it itself
    172177         */
    173         fd=open(trace->uridata,O_LARGEFILE|O_RDONLY);
     178        fd=open(trace->uridata,O_LARGEFILE|O_RDONLY|O_BINARY);
    174179        if (fd==-1) {
    175180                trace_set_err(trace,errno,"Unable to open %s",trace->uridata);
     
    204209         * as zlib doesn't always do it itself
    205210         */
    206         fd=open(trace->uridata,fileflag|O_LARGEFILE,0666);
     211        fd=open(trace->uridata,fileflag|O_LARGEFILE|O_BINARY,0666);
    207212        if (fd==-1) {
    208213                trace_set_err_out(trace,
Note: See TracChangeset for help on using the changeset viewer.