diff options
author | Kresten Krab Thorup <krab@gcc.gnu.org> | 1993-09-22 17:59:50 +0000 |
---|---|---|
committer | Kresten Krab Thorup <krab@gcc.gnu.org> | 1993-09-22 17:59:50 +0000 |
commit | d4b130122f43c3ec6b5ec5955de0887ef26c6dd5 (patch) | |
tree | 11c77411a85200843735d5b03e6482338ea47bae | |
parent | 2f2c485abddce319c5f2fa9e8f44a458655e7404 (diff) | |
download | gcc-d4b130122f43c3ec6b5ec5955de0887ef26c6dd5.zip gcc-d4b130122f43c3ec6b5ec5955de0887ef26c6dd5.tar.gz gcc-d4b130122f43c3ec6b5ec5955de0887ef26c6dd5.tar.bz2 |
(objc_write_type, objc_write_types): Take take char** args for writing strings in stead of char* to match NeXT.
(objc_write_type, objc_write_types): Take
take char** args for writing strings in stead of char* to
match NeXT. Also correct some typos in error messages.
From-SVN: r5398
-rw-r--r-- | gcc/objc/archive.c | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/gcc/objc/archive.c b/gcc/objc/archive.c index ad822fa..87bd585 100644 --- a/gcc/objc/archive.c +++ b/gcc/objc/archive.c @@ -34,7 +34,7 @@ You should have received a copy of the GNU General Public License along with #include "typedstream.h" #define __objc_fatal(format, args...) \ - { fprintf(stderr, "archining: "); \ + { fprintf(stderr, "archiving: "); \ fprintf(stderr, format, ## args); \ fprintf(stderr, "\n"); abort(); } @@ -854,7 +854,7 @@ objc_sizeof_type(const char* type) break; default: - fprintf(stderr, "objc_write_type: cannot parse typespec: %s\n", type); + fprintf(stderr, "objc_sizeof_type: cannot parse typespec: %s\n", type); abort(); } } @@ -892,7 +892,7 @@ __objc_skip_type (const char* type) break; default: - fprintf(stderr, "objc_read_types: cannot parse typespec: %s\n", type); + fprintf(stderr, "__objc_skip_type: cannot parse typespec: %s\n", type); abort(); } } @@ -949,11 +949,11 @@ objc_write_type(TypedStream* stream, const char* type, const void* data) break; case _C_CHARPTR: - return objc_write_string (stream, (char*)data, strlen((char*)data)); + return objc_write_string (stream, *(char**)data, strlen(*(char**)data)); break; case _C_ATOM: - return objc_write_string_atomic (stream, (char*)data, strlen((char*)data)); + return objc_write_string_atomic (stream, *(char**)data, strlen(*(char**)data)); break; case _C_ARY_B: @@ -1034,7 +1034,7 @@ objc_read_type(TypedStream* stream, const char* type, void* data) break; default: - fprintf(stderr, "objc_write_type: cannot parse typespec: %s\n", type); + fprintf(stderr, "objc_read_type: cannot parse typespec: %s\n", type); abort(); } } @@ -1103,15 +1103,15 @@ objc_write_types (TypedStream* stream, const char* type, ...) case _C_CHARPTR: { - char* str = va_arg(args, char*); - res = objc_write_string (stream, str, strlen(str)); + char** str = va_arg(args, char**); + res = objc_write_string (stream, *str, strlen(*str)); } break; case _C_ATOM: { - char* str = va_arg(args, char*); - res = objc_write_string_atomic (stream, str, strlen(str)); + char** str = va_arg(args, char**); + res = objc_write_string_atomic (stream, *str, strlen(*str)); } break; @@ -1128,7 +1128,7 @@ objc_write_types (TypedStream* stream, const char* type, ...) break; default: - fprintf(stderr, "objc_write_type: cannot parse typespec: %s\n", type); + fprintf(stderr, "objc_write_types: cannot parse typespec: %s\n", type); abort(); } } @@ -1213,7 +1213,7 @@ objc_read_types(TypedStream* stream, const char* type, ...) break; default: - fprintf(stderr, "objc_read_type: cannot parse typespec: %s\n", type); + fprintf(stderr, "objc_read_types: cannot parse typespec: %s\n", type); abort(); } } |