summaryrefslogtreecommitdiff
path: root/asn1.c
AgeCommit message (Collapse)AuthorFilesLines
2013-10-14asn1: fix use-after-free in asn1_writeJeff Layton1-1/+0
If the talloc_realloc() fails, asn1_write calls talloc_free on the context and then immediately dereferences the pointer. Fix this by skipping the talloc_free here. Let the caller handle it. Signed-off-by: Jeff Layton <jlayton@samba.org>
2013-10-10asn1: remove some usused functionsJeff Layton1-638/+0
This cuts 30k out of the cifs.upcall binary on my x86_64 box. Signed-off-by: Jeff Layton <jlayton@samba.org>
2012-04-15asn1: fix up some compiler warnings in asn1.cJeff Layton1-5/+10
These have been around for quite some time. gcc -DHAVE_CONFIG_H -I. -Wall -Wextra -g -O2 -MT asn1.o -MD -MP -MF .deps/asn1.Tpo -c -o asn1.o asn1.c asn1.c: In function ‘asn1_write’: asn1.c:45:19: warning: comparison between signed and unsigned integer expressions [-Wsign-compare] asn1.c: In function ‘asn1_peek’: asn1.c:411:22: warning: comparison between signed and unsigned integer expressions [-Wsign-compare] asn1.c: In function ‘asn1_tag_remaining’: asn1.c:541:16: warning: comparison between signed and unsigned integer expressions [-Wsign-compare] asn1.c: In function ‘_ber_read_OID_String_impl’: asn1.c:570:22: warning: comparison between signed and unsigned integer expressions [-Wsign-compare] Almost all of these are due to the fact that asn1_data->ofs is a signed value, and ->length is unsigned. This should clear the way to add -Werror to the cflags in the near future. Signed-off-by: Jeff Layton <jlayton@samba.org>
2010-02-08silence some build warningsJeff Layton1-1/+1
mount.cifs.c: In function 'main': mount.cifs.c:1201: warning: 'dev_name' may be used uninitialized in this function mount.cifs.c:1217: warning: 'addr6' may be used uninitialized in this function asn1.c: In function 'ber_read_OID_String': asn1.c:591: warning: 'bytes_eaten' may be used uninitialized in this function Signed-off-by: Jeff Layton <jlayton@redhat.com>
2010-02-07asn1.c: remove a couple of unneeded functionsJeff Layton1-99/+0
These depends on some utility functions that we don't have and we aren't planning to use them anyway. Just remove them. Signed-off-by: Jeff Layton <jlayton@redhat.com>
2010-02-07add asn.1 files from samba treeJeff Layton1-0/+948
Signed-off-by: Jeff Layton <jlayton@redhat.com>