Ignore:
Timestamp:
Mar 13, 2011, 8:39:08 PM (11 years ago)
Author:
jordan
Message:

(trunk libT) add attribution for the fallback tr_htonll() and tr_ntohll() code

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/libtransmission/utils.c

    r12157 r12158  
    16591659    return htonll( x );
    16601660#else
     1661    /* fallback code by Runner and Juan Carlos Cobas at
     1662     * http://www.codeproject.com/KB/cpp/endianness.aspx */
    16611663    return (((uint64_t)(htonl((int)((x << 32) >> 32))) << 32) |
    16621664                     (unsigned int)htonl(((int)(x >> 32))));
     
    16701672    return ntohll( x );
    16711673#else
     1674    /* fallback code by Runner and Juan Carlos Cobas at
     1675     * http://www.codeproject.com/KB/cpp/endianness.aspx */
    16721676    return (((uint64_t)(ntohl((int)((x << 32) >> 32))) << 32) |
    16731677                     (unsigned int)ntohl(((int)(x >> 32))));
Note: See TracChangeset for help on using the changeset viewer.