From 8f8c44cb4fe52e7eb0440abcbc052e0f80cf8037 Mon Sep 17 00:00:00 2001 From: "Kaveh R. Ghazi" Date: Sat, 15 Jun 2002 17:50:14 +0000 Subject: Object.m: Fix signed/unsigned warning. * Object.m: Fix signed/unsigned warning. * Protocol.m: Likewise. * archive.c: Always include stdlib.h. (objc_read_short, objc_read_unsigned_short, objc_read_int, objc_read_long, __objc_read_nbyte_uint, __objc_read_nbyte_ulong): Fix signed/unsigned warning. (objc_write_type, objc_read_type, objc_write_types, objc_read_types): Ensure ctype 8-bit safety. (__objc_no_write, __objc_no_read): Mark unused parameters. * class.c (class_table_setup): Specify void arg. * encoding.c (atoi, objc_sizeof_type, objc_alignof_type, objc_skip_typespec, objc_skip_offset, objc_layout_structure_next_member): Ensure ctype 8-bit safety. (objc_layout_structure_next_member): Ensure variables are initialized. * gc.c (__objc_generate_gc_type_description, class_ivar_set_gcinvisible): Mark unused parameters. * init.c (__objc_send_load, __objc_destroy_class_tree_node): Mark unused parameters. (__objc_init_protocols) Fix signed/unsigned warning. * nil_method.c (nil_method): Mark unused parameters. * thr.h (objc_thread_callback): Specify void arg. * sarray.c (sarray_new, sarray_realloc, sarray_free): Fix signed/unsigned warning. (sarray_free): Fix formatting. * selector.c (sel_types_match): Ensure ctype 8-bit safety. * sendmsg.c (__objc_init_install_dtable) Mark unused parameters. From-SVN: r54649 --- libobjc/sarray.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'libobjc/sarray.c') diff --git a/libobjc/sarray.c b/libobjc/sarray.c index 4625fbe..14135af 100644 --- a/libobjc/sarray.c +++ b/libobjc/sarray.c @@ -211,7 +211,7 @@ sarray_new (int size, void* default_element) size_t num_indices = ((size-1)/BUCKET_SIZE)+1; struct sbucket ** new_buckets; #endif - int counter; + size_t counter; assert(size > 0); @@ -302,7 +302,7 @@ sarray_realloc(struct sarray* array, int newsize) #endif - int counter; + size_t counter; assert(newsize > 0); @@ -382,8 +382,8 @@ sarray_realloc(struct sarray* array, int newsize) /* Free a sparse array allocated with sarray_new */ void -sarray_free(struct sarray* array) { - +sarray_free(struct sarray* array) +{ #ifdef OBJC_SPARSE3 size_t old_max_index = (array->capacity-1)/INDEX_CAPACITY; struct sindex ** old_indices; @@ -391,7 +391,7 @@ sarray_free(struct sarray* array) { size_t old_max_index = (array->capacity-1)/BUCKET_SIZE; struct sbucket ** old_buckets; #endif - int counter = 0; + size_t counter = 0; assert(array->ref_count != 0); /* Freed multiple times!!! */ -- cgit v1.1