Ignore:
Timestamp:
Aug 15, 2010, 11:45:58 PM (11 years ago)
Author:
charles
Message:

(trunk libT) if we compile with TR_EMBEDDED, use Z_DEFAULT_COMPRESSION. otherwise, use Z_BEST_COMPRESSION

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/libtransmission/rpc-server.c

    r11119 r11179  
    331331        if( !server->isStreamInitialized )
    332332        {
     333            int compressionLevel;
     334
    333335            server->isStreamInitialized = TRUE;
    334336            server->stream.zalloc = (alloc_func) Z_NULL;
     
    338340            /* zlib's manual says: "Add 16 to windowBits to write a simple gzip header
    339341             * and trailer around the compressed data instead of a zlib wrapper." */
    340             deflateInit2( &server->stream, Z_DEFAULT_COMPRESSION, Z_DEFLATED, 15+16, 8, Z_DEFAULT_STRATEGY );
     342#ifdef TR_EMBEDDED
     343            compressionLevel = Z_DEFAULT_COMPRESSION;
     344#else
     345            compressionLevel = Z_BEST_COMPRESSION;
     346#endif
     347            deflateInit2( &server->stream, compressionLevel, Z_DEFLATED, 15+16, 8, Z_DEFAULT_STRATEGY );
    341348        }
    342349
Note: See TracChangeset for help on using the changeset viewer.