source: trunk/third-party/utp_config.h @ 14381

Last change on this file since 14381 was 14381, checked in by mikedld, 8 years ago

Make utp_config.h usable with MSVC (#warning directive is not standard)

File size: 998 bytes
Line 
1#define CCONTROL_TARGET (100 * 1000) // us
2#define RATE_CHECK_INTERVAL 10000 // ms
3#define DYNAMIC_PACKET_SIZE_ENABLED false
4#define DYNAMIC_PACKET_SIZE_FACTOR 2
5// This should return the global number of bytes sent, used for determining dynamic
6// packet size based on rate
7
8#ifdef _MSC_VER
9#pragma warning()
10#pragma message(implement this in libtransmission)
11#else
12#warning implement this in libtransmission
13#endif
14uint64 UTP_GetGlobalUTPBytesSent(const struct sockaddr *remote, socklen_t remotelen) { return 0; }
15
16enum bandwidth_type_t {
17        payload_bandwidth, connect_overhead,
18        close_overhead, ack_overhead,
19        header_overhead, retransmit_overhead
20};
21
22#ifdef _WIN32
23#define I64u "%I64u"
24#else
25#define I64u "%Lu"
26#endif
27#ifdef _WIN32
28#define snprintf _snprintf
29#endif
30
31#define g_log_utp 0
32#define g_log_utp_verbose 0
33void utp_log(char const* fmt, ...)
34{
35        /*
36        printf("[%u] ", UTP_GetMilliseconds());
37        va_list vl;
38        va_start(vl, fmt);
39        vprintf(fmt, vl);
40        va_end(vl);
41        puts("");
42        fflush(stdout);
43        */
44};
Note: See TracBrowser for help on using the repository browser.