Ignore:
Timestamp:
Jul 2, 2011, 4:01:14 PM (14 years ago)
Author:
Herwig Bauernfeind
Message:

Samba 3.5: Update vendor to version 3.5.9

File:
1 edited

Legend:

Unmodified
Added
Removed
  • vendor/current/lib/util/asn1.c

    r414 r597  
    717717{
    718718        uint8_t b;
     719        bool first_byte = true;
    719720        *i = 0;
    720721
    721722        while (!data->has_error && asn1_tag_remaining(data)>0) {
    722723                if (!asn1_read_uint8(data, &b)) return false;
     724                if (first_byte) {
     725                        if (b & 0x80) {
     726                                /* Number is negative.
     727                                   Set i to -1 for sign extend. */
     728                                *i = -1;
     729                        }
     730                        first_byte = false;
     731                }
    723732                *i = (*i << 8) + b;
    724733        }
Note: See TracChangeset for help on using the changeset viewer.