summaryrefslogtreecommitdiff
path: root/source4/libcli/util/asn1.c
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2004-05-25 13:57:39 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 12:56:14 -0500
commit579c13da43d5b40ac6d6c1436399fbc1d8dfd054 (patch)
tree42299570746f2d7f80356b689cb15e3db6c53d3c /source4/libcli/util/asn1.c
parent81e8de9ca85fe9a6658beb1dab0d231c13cda063 (diff)
downloadsamba-579c13da43d5b40ac6d6c1436399fbc1d8dfd054.tar.gz
samba-579c13da43d5b40ac6d6c1436399fbc1d8dfd054.tar.bz2
samba-579c13da43d5b40ac6d6c1436399fbc1d8dfd054.zip
r873: converted samba4 to use real 64 bit integers instead of
structures. This was suggested by metze recently. I checked on the build farm and all the machines we have support 64 bit ints, and support the LL suffix for 64 bit constants. I suspect some won't support strtoll() and related functions, so we will probably need replacements for those. (This used to be commit 9a9244a1c66654c12abe4379661cba83a73c4c21)
Diffstat (limited to 'source4/libcli/util/asn1.c')
-rw-r--r--source4/libcli/util/asn1.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/source4/libcli/util/asn1.c b/source4/libcli/util/asn1.c
index 09d4fbb6c9..07c692f700 100644
--- a/source4/libcli/util/asn1.c
+++ b/source4/libcli/util/asn1.c
@@ -315,17 +315,17 @@ int asn1_tag_remaining(ASN1_DATA *data)
BOOL asn1_read_OID(ASN1_DATA *data, char **OID)
{
uint8 b;
- pstring oid;
+ pstring aoid;
fstring el;
if (!asn1_start_tag(data, ASN1_OID)) return False;
asn1_read_uint8(data, &b);
- oid[0] = 0;
+ aoid[0] = 0;
snprintf(el, sizeof(el), "%u", b/40);
- pstrcat(oid, el);
+ pstrcat(aoid, el);
snprintf(el, sizeof(el), " %u", b%40);
- pstrcat(oid, el);
+ pstrcat(aoid, el);
while (asn1_tag_remaining(data) > 0) {
unsigned v = 0;
@@ -334,12 +334,12 @@ BOOL asn1_read_OID(ASN1_DATA *data, char **OID)
v = (v<<7) | (b&0x7f);
} while (!data->has_error && b & 0x80);
snprintf(el, sizeof(el), " %u", v);
- pstrcat(oid, el);
+ pstrcat(aoid, el);
}
asn1_end_tag(data);
- *OID = strdup(oid);
+ *OID = strdup(aoid);
return !data->has_error;
}