diff options
Diffstat (limited to 'tderesources/groupwise/soap/stdsoap2.cpp')
-rw-r--r-- | tderesources/groupwise/soap/stdsoap2.cpp | 486 |
1 files changed, 243 insertions, 243 deletions
diff --git a/tderesources/groupwise/soap/stdsoap2.cpp b/tderesources/groupwise/soap/stdsoap2.cpp index 72c464d24..b83b2bb49 100644 --- a/tderesources/groupwise/soap/stdsoap2.cpp +++ b/tderesources/groupwise/soap/stdsoap2.cpp @@ -416,7 +416,7 @@ static int tcp_done = 0; #ifndef PALM_1 static int fsend(struct soap *soap, const char *s, size_t n) -{ register int nwritten; +{ int nwritten; #if defined(__cplusplus) && !defined(WITH_LEAN) if (soap->os) { soap->os->write(s, n); @@ -443,7 +443,7 @@ fsend(struct soap *soap, const char *s, size_t n) FD_ZERO(&fd); FD_SET((SOAP_SOCKET)soap->socket, &fd); for (;;) - { register int r = select((SOAP_SOCKET)(soap->socket + 1), NULL, &fd, &fd, &timeout); + { int r = select((SOAP_SOCKET)(soap->socket + 1), NULL, &fd, &fd, &timeout); if (r > 0) break; if (!r) @@ -566,7 +566,7 @@ int SOAP_FMAC2 soap_flush_raw(struct soap *soap, const char *s, size_t n) { if ((soap->mode & SOAP_IO) == SOAP_IO_STORE) - { register char *t; + { char *t; if (!(t = (char*)soap_push_block(soap, n))) return soap->error = SOAP_EOM; memcpy(t, s, n); @@ -647,7 +647,7 @@ soap_send_raw(struct soap *soap, const char *s, size_t n) return SOAP_OK; } if (soap->mode & SOAP_IO) - { register size_t i = SOAP_BUFLEN - soap->bufidx; + { size_t i = SOAP_BUFLEN - soap->bufidx; while (n >= i) { memcpy(soap->buf + soap->bufidx, s, i); soap->bufidx = SOAP_BUFLEN; @@ -711,7 +711,7 @@ soap_send3(struct soap *soap, const char *s1, const char *s2, const char *s3) #ifndef PALM_1 static size_t frecv(struct soap *soap, char *s, size_t n) -{ register int r; +{ int r; soap->errnum = 0; #if defined(__cplusplus) && !defined(WITH_LEAN) if (soap->is) @@ -867,13 +867,13 @@ SOAP_FMAC1 int SOAP_FMAC2 soap_recv_raw(struct soap *soap) -{ register size_t ret; +{ size_t ret; #ifdef WITH_ZLIB if (soap->mode & SOAP_ENC_ZLIB) { if (soap->d_stream.next_out == Z_NULL) return EOF; if (soap->d_stream.avail_in || !soap->d_stream.avail_out) - { register int r; + { int r; DBGLOG(TEST, SOAP_MESSAGE(fdebug, "Inflating\n")); soap->d_stream.next_out = (Byte*)soap->buf; soap->d_stream.avail_out = SOAP_BUFLEN; @@ -918,7 +918,7 @@ chunk_again: soap->chunksize -= ret; } else - { register soap_wchar c; + { soap_wchar c; char *t, tmp[8]; t = tmp; if (!soap->chunkbuflen) @@ -980,7 +980,7 @@ chunk_again: #endif #ifdef WITH_ZLIB if (soap->mode & SOAP_ENC_ZLIB) - { register int r; + { int r; memcpy(soap->z_buf, soap->buf, SOAP_BUFLEN); soap->d_stream.next_in = (Byte*)(soap->z_buf + soap->bufidx); soap->d_stream.avail_in = (unsigned int)ret; @@ -1093,7 +1093,7 @@ SOAP_FMAC1 soap_wchar SOAP_FMAC2 soap_getchar(struct soap *soap) -{ register soap_wchar c; +{ soap_wchar c; if (soap->ahead) { c = soap->ahead; soap->ahead = 0; @@ -1152,9 +1152,9 @@ soap_str_code(const struct soap_code_map *map, long code) static soap_wchar soap_char(struct soap *soap) { char tmp[8]; - register int i; - register soap_wchar c; - register char *s = tmp; + int i; + soap_wchar c; + char *s = tmp; for (i = 0; i < 7; i++) { c = soap_get1(soap); if (c == ';' || (int)c == EOF) @@ -1211,7 +1211,7 @@ SOAP_FMAC1 soap_wchar SOAP_FMAC2 soap_get(struct soap *soap) -{ register soap_wchar c; +{ soap_wchar c; c = soap->ahead; if (c) soap->ahead = 0; @@ -1239,7 +1239,7 @@ soap_get(struct soap *soap) do c = soap_get1(soap); while (soap_blank(c)); if (c == '!' || c == '?' || c == '%') - { register int k = 1; + { int k = 1; if (c == '!') { c = soap_get1(soap); if (c == '[') @@ -1325,7 +1325,7 @@ soap_tell(struct soap *soap) SOAP_FMAC1 int SOAP_FMAC2 -soap_pututf8(struct soap *soap, register unsigned long c) +soap_pututf8(struct soap *soap, unsigned long c) { char tmp[16]; if (c > 0 && c < 0x80) { *tmp = (char)c; @@ -1333,7 +1333,7 @@ soap_pututf8(struct soap *soap, register unsigned long c) } #ifndef WITH_LEAN if (soap->mode & SOAP_XML_CANONICAL) - { register char *t = tmp; + { char *t = tmp; if (c < 0x0800) *t++ = (char)(0xC0 | ((c >> 6) & 0x1F)); else @@ -1371,7 +1371,7 @@ SOAP_FMAC1 soap_wchar SOAP_FMAC2 soap_getutf8(struct soap *soap) -{ register soap_wchar c, c1, c2, c3, c4; +{ soap_wchar c, c1, c2, c3, c4; c = soap_get(soap); if (c < 0x80 || (soap->mode & SOAP_ENC_LATIN)) return c; @@ -1403,7 +1403,7 @@ int SOAP_FMAC2 soap_puthex(struct soap *soap, const unsigned char *s, int n) { char d[2]; - register int i; + int i; #ifdef WITH_DOM if ((soap->mode & SOAP_XML_DOM) && soap->dom) { if (!(soap->dom->data = soap_s2hex(soap, s, NULL, n))) @@ -1412,7 +1412,7 @@ soap_puthex(struct soap *soap, const unsigned char *s, int n) } #endif for (i = 0; i < n; i++) - { register int m = *s++; + { int m = *s++; d[0] = (char)((m >> 4) + (m > 159 ? '7' : '0')); m &= 0x0F; d[1] = (char)(m + (m > 9 ? '7' : '0')); @@ -1433,16 +1433,16 @@ soap_gethex(struct soap *soap, int *n) #ifdef WITH_FAST soap->labidx = 0; for (;;) - { register char *s; - register int i, k; + { char *s; + int i, k; if (soap_append_lab(soap, NULL, 0)) return NULL; s = soap->labbuf + soap->labidx; k = soap->lablen - soap->labidx; soap->labidx = soap->lablen; for (i = 0; i < k; i++) - { register char d1, d2; - register soap_wchar c; + { char d1, d2; + soap_wchar c; c = soap_get(soap); if (soap_isxdigit(c)) { d1 = (char)c; @@ -1471,15 +1471,15 @@ soap_gethex(struct soap *soap, int *n) if (soap_new_block(soap)) return NULL; for (;;) - { register int i; - register char *s = (char*)soap_push_block(soap, SOAP_BLKLEN); + { int i; + char *s = (char*)soap_push_block(soap, SOAP_BLKLEN); if (!s) { soap_end_block(soap); return NULL; } for (i = 0; i < SOAP_BLKLEN; i++) - { register char d1, d2; - register soap_wchar c = soap_get(soap); + { char d1, d2; + soap_wchar c = soap_get(soap); if (soap_isxdigit(c)) { d1 = (char)c; c = soap_get(soap); @@ -1512,8 +1512,8 @@ SOAP_FMAC1 int SOAP_FMAC2 soap_putbase64(struct soap *soap, const unsigned char *s, int n) -{ register int i; - register unsigned long m; +{ int i; + unsigned long m; char d[4]; if (!s) return SOAP_OK; @@ -1560,8 +1560,8 @@ soap_getbase64(struct soap *soap, int *n, int malloc_flag) #ifdef WITH_FAST soap->labidx = 0; for (;;) - { register int i, k; - register char *s; + { int i, k; + char *s; if (soap_append_lab(soap, NULL, 2)) return NULL; s = soap->labbuf + soap->labidx; @@ -1570,10 +1570,10 @@ soap_getbase64(struct soap *soap, int *n, int malloc_flag) if (!s) return NULL; for (i = 0; i < k; i += 3) - { register unsigned long m = 0; - register int j = 0; + { unsigned long m = 0; + int j = 0; do - { register soap_wchar c = soap_get(soap); + { soap_wchar c = soap_get(soap); if (c == '=' || c < 0) { unsigned char *p; switch (j) @@ -1613,17 +1613,17 @@ soap_getbase64(struct soap *soap, int *n, int malloc_flag) if (soap_new_block(soap)) return NULL; for (;;) - { register int i; - register char *s = (char*)soap_push_block(soap, 3 * SOAP_BLKLEN); /* must be multiple of 3 */ + { int i; + char *s = (char*)soap_push_block(soap, 3 * SOAP_BLKLEN); /* must be multiple of 3 */ if (!s) { soap_end_block(soap); return NULL; } for (i = 0; i < SOAP_BLKLEN; i++) - { register unsigned long m = 0; - register int j = 0; + { unsigned long m = 0; + int j = 0; do - { register soap_wchar c = soap_get(soap); + { soap_wchar c = soap_get(soap); if (c == '=' || c < 0) { unsigned char *p; i *= 3; @@ -1785,12 +1785,12 @@ soap_pop_block(struct soap *soap) static void soap_update_ptrs(struct soap *soap, char *start, char *end, long offset) { int i; - register struct soap_ilist *ip; - register struct soap_flist *fp; + struct soap_ilist *ip; + struct soap_flist *fp; #ifndef WITH_LEANER - register struct soap_xlist *xp; + struct soap_xlist *xp; #endif - register void *p, **q; + void *p, **q; for (i = 0; i < SOAP_IDHASH; i++) { for (ip = soap->iht[i]; ip; ip = ip->next) { if (ip->ptr && (char*)ip->ptr >= start && (char*)ip->ptr < end) @@ -1838,11 +1838,11 @@ soap_update_ptrs(struct soap *soap, char *start, char *end, long offset) #ifndef WITH_NOIDREF #ifndef PALM_1 static int -soap_has_copies(struct soap *soap, register const char *start, register const char *end) -{ register int i; - register struct soap_ilist *ip; - register struct soap_flist *fp; - register const char *p; +soap_has_copies(struct soap *soap, const char *start, const char *end) +{ int i; + struct soap_ilist *ip; + struct soap_flist *fp; + const char *p; for (i = 0; i < SOAP_IDHASH; i++) { for (ip = soap->iht[i]; ip; ip = ip->next) { for (p = (const char*)ip->copy; p; p = *(const char**)p) @@ -1865,15 +1865,15 @@ SOAP_FMAC1 int SOAP_FMAC2 soap_resolve(struct soap *soap) -{ register int i; - register struct soap_ilist *ip; - register struct soap_flist *fp; +{ int i; + struct soap_ilist *ip; + struct soap_flist *fp; short flag; DBGLOG(TEST, SOAP_MESSAGE(fdebug, "Resolving forwarded data\n")); for (i = 0; i < SOAP_IDHASH; i++) { for (ip = soap->iht[i]; ip; ip = ip->next) { if (ip->ptr) - { register void *p, **q, *r; + { void *p, **q, *r; q = (void**)ip->link; ip->link = NULL; r = ip->ptr; @@ -1899,7 +1899,7 @@ soap_resolve(struct soap *soap) { for (ip = soap->iht[i]; ip; ip = ip->next) { if (ip->ptr && !soap_has_copies(soap, (const char*)ip->ptr, (const char*)ip->ptr + ip->size)) { if (ip->copy) - { register void *p, **q = (void**)ip->copy; + { void *p, **q = (void**)ip->copy; DBGLOG(TEST, if (q) SOAP_MESSAGE(fdebug, "Traversing copy chain to resolve id='%s'\n", ip->id)); ip->copy = NULL; do @@ -1911,11 +1911,11 @@ soap_resolve(struct soap *soap) flag = 1; } for (fp = ip->flist; fp; fp = ip->flist) - { register unsigned int k = fp->level; - register void *p = ip->ptr; + { unsigned int k = fp->level; + void *p = ip->ptr; DBGLOG(TEST, SOAP_MESSAGE(fdebug, "Resolving forwarded data type=%d location=%p level=%u,%u id='%s'\n", ip->type, p, ip->level, fp->level, ip->id)); while (ip->level < k) - { register void **q = (void**)soap_malloc(soap, sizeof(void*)); + { void **q = (void**)soap_malloc(soap, sizeof(void*)); if (!q) return soap->error; *q = p; @@ -2044,8 +2044,8 @@ SOAP_FMAC1 char* SOAP_FMAC2 soap_save_block(struct soap *soap, char *p, int flag) -{ register size_t n; - register char *q, *s; +{ size_t n; + char *q, *s; DBGLOG(TEST, SOAP_MESSAGE(fdebug, "Save all blocks in contiguous memory space of %u bytes (%p->%p)\n", (unsigned int)soap->blist->size, soap->blist->ptr, p)); if (soap->blist->size) { if (!p) @@ -2137,7 +2137,7 @@ SOAP_FMAC1 char * SOAP_FMAC2 soap_putoffsets(struct soap *soap, const int *offset, int dim) -{ register int i; +{ int i; sprintf(soap->arrayOffset, "[%d", offset[0]); for (i = 1; i < dim; i++) sprintf(soap->arrayOffset + strlen(soap->arrayOffset), ",%d", offset[i]); @@ -2152,7 +2152,7 @@ SOAP_FMAC1 int SOAP_FMAC2 soap_size(const int *size, int dim) -{ register int i, n = size[0]; +{ int i, n = size[0]; for (i = 1; i < dim; i++) n *= size[i]; return n; @@ -2165,7 +2165,7 @@ SOAP_FMAC1 int SOAP_FMAC2 soap_getoffsets(const char *attr, const int *size, int *offset, int dim) -{ register int i, j = 0; +{ int i, j = 0; if (offset) for (i = 0; i < dim && attr && *attr; i++) { attr++; @@ -2190,7 +2190,7 @@ SOAP_FMAC1 int SOAP_FMAC2 soap_getsize(const char *attr1, const char *attr2, int *j) -{ register int n, k; +{ int n, k; char *s; *j = 0; if (!*attr1) @@ -2229,7 +2229,7 @@ SOAP_FMAC1 int SOAP_FMAC2 soap_getsizes(const char *attr, int *size, int dim) -{ register int i, k, n; +{ int i, k, n; if (!*attr) return -1; i = strlen(attr); @@ -2253,7 +2253,7 @@ SOAP_FMAC1 int SOAP_FMAC2 soap_getposition(const char *attr, int *pos) -{ register int i, n; +{ int i, n; if (!*attr) return -1; n = 0; @@ -2275,8 +2275,8 @@ SOAP_FMAC1 int SOAP_FMAC2 soap_push_namespace(struct soap *soap, const char *id, const char *ns) -{ register struct soap_nlist *np; - register struct Namespace *p; +{ struct soap_nlist *np; + struct Namespace *p; np = (struct soap_nlist*)SOAP_MALLOC(soap, sizeof(struct soap_nlist) + strlen(id)); if (!np) return soap->error = SOAP_EOM; @@ -2289,7 +2289,7 @@ soap_push_namespace(struct soap *soap, const char *id, const char *ns) DBGLOG(TEST, SOAP_MESSAGE(fdebug, "Push namespace binding (level=%u) '%s' '%s'\n", soap->level, id, ns)); p = soap->local_namespaces; if (p) - { register short i = 0; + { short i = 0; for (; p->id; p++, i++) { if (p->ns && !strcmp(ns, p->ns)) { if (p->out) @@ -2332,7 +2332,7 @@ SOAP_FMAC1 void SOAP_FMAC2 soap_pop_namespace(struct soap *soap) -{ register struct soap_nlist *np; +{ struct soap_nlist *np; while (soap->nlist && soap->nlist->level >= soap->level) { np = soap->nlist->next; DBGLOG(TEST, SOAP_MESSAGE(fdebug, "Popped namespace binding (level=%u) '%s'\n", soap->level, soap->nlist->id)); @@ -2350,7 +2350,7 @@ SOAP_FMAC1 int SOAP_FMAC2 soap_match_namespace(struct soap *soap, const char *id1, const char *id2, int n1, int n2) -{ register struct soap_nlist *np = soap->nlist; +{ struct soap_nlist *np = soap->nlist; while (np && (strncmp(np->id, id1, n1) || np->id[n1])) np = np->next; if (np) @@ -2371,8 +2371,8 @@ int SOAP_FMAC2 soap_tag_cmp(const char *s, const char *t) { for (;;) - { register int c1 = *s; - register int c2 = *t; + { int c1 = *s; + int c2 = *t; if (!c1 || c1 == '"') break; if (c2 != '-') @@ -2418,7 +2418,7 @@ SOAP_FMAC1 int SOAP_FMAC2 soap_match_tag(struct soap *soap, const char *tag1, const char *tag2) -{ register const char *s, *t; +{ const char *s, *t; if (!tag1 || !tag2 || !*tag2) return SOAP_OK; s = strchr(tag1, ':'); @@ -2844,7 +2844,7 @@ soap_done(struct soap *soap) soap_free_cookies(soap); #endif while (soap->plugins) - { register struct soap_plugin *p = soap->plugins->next; + { struct soap_plugin *p = soap->plugins->next; DBGLOG(TEST, SOAP_MESSAGE(fdebug, "Removing plugin '%s'\n", soap->plugins->id)); if (soap->plugins->fcopy || !soap->copy) soap->plugins->fdelete(soap, soap->plugins); @@ -2941,7 +2941,7 @@ soap_cleanup(struct soap *soap) #ifndef PALM_1 static const char* tcp_error(struct soap *soap) -{ register const char *msg = NULL; +{ const char *msg = NULL; switch (soap->errmode) { case 0: msg = soap_strerror(soap); @@ -2970,7 +2970,7 @@ tcp_error(struct soap *soap) #ifndef PALM_1 static const char* http_error(struct soap *soap, int status) -{ register const char *msg = SOAP_STR_EOS; +{ const char *msg = SOAP_STR_EOS; #ifndef WITH_LEAN msg = soap_str_code(h_http_error_codes, status); if (!msg) @@ -3059,7 +3059,7 @@ tcp_connect(struct soap *soap, const char *endpoint, const char *host, int port) struct addrinfo hints, *res, *ressave; int err; #endif - register int fd; + int fd; #ifndef WITH_LEAN int len = SOAP_BUFLEN; int set = 1; @@ -3928,7 +3928,7 @@ SOAP_FMAC1 int SOAP_FMAC2 soap_closesock(struct soap *soap) -{ register int status = soap->error; +{ int status = soap->error; if (status == SOAP_EOF || status == SOAP_TCP_ERROR || status == SOAP_SSL_ERROR || !soap->keep_alive) { if (soap->fclose && (soap->error = soap->fclose(soap))) return soap->error; @@ -3951,8 +3951,8 @@ soap_closesock(struct soap *soap) SOAP_FMAC1 size_t SOAP_FMAC2 -soap_hash(register const char *s) -{ register size_t h = 0; +soap_hash(const char *s) +{ size_t h = 0; while (*s) h = 65599*h + *s++; return h % SOAP_IDHASH; @@ -3965,7 +3965,7 @@ soap_hash(register const char *s) #ifndef PALM_1 static void soap_init_pht(struct soap *soap) -{ register int i; +{ int i; DBGLOG(TEST, SOAP_MESSAGE(fdebug, "Initializing pointer hashtable\n")); for (i = 0; i < (int)SOAP_PTRHASH; i++) soap->pht[i] = NULL; @@ -4011,8 +4011,8 @@ soap_new2(soap_mode imode, soap_mode omode) #ifndef PALM_1 static void soap_free_pht(struct soap *soap) -{ register struct soap_plist *pp, *next; - register int i; +{ struct soap_plist *pp, *next; + int i; DBGLOG(TEST, SOAP_MESSAGE(fdebug, "Free pointer hashtable\n")); for (i = 0; i < (int)SOAP_PTRHASH; i++) { for (pp = soap->pht[i]; pp; pp = next) @@ -4032,7 +4032,7 @@ SOAP_FMAC1 int SOAP_FMAC2 soap_embed(struct soap *soap, const void *p, const struct soap_array *a, int n, const char *tag, int type) -{ register int i; +{ int i; struct soap_plist *pp; if (soap->version != 1) soap->encoding = 1; @@ -4058,7 +4058,7 @@ SOAP_FMAC1 int SOAP_FMAC2 soap_pointer_lookup(struct soap *soap, const void *p, int type, struct soap_plist **ppp) -{ register struct soap_plist *pp; +{ struct soap_plist *pp; *ppp = NULL; if (p) for (pp = soap->pht[soap_hash_ptr(p)]; pp; pp = pp->next) @@ -4080,8 +4080,8 @@ SOAP_FMAC1 int SOAP_FMAC2 soap_pointer_enter(struct soap *soap, const void *p, const struct soap_array *a, int n, int type, struct soap_plist **ppp) -{ register int h; - register struct soap_plist *pp = *ppp = (struct soap_plist*)SOAP_MALLOC(soap, sizeof(struct soap_plist)); +{ int h; + struct soap_plist *pp = *ppp = (struct soap_plist*)SOAP_MALLOC(soap, sizeof(struct soap_plist)); if (!pp) return 0; if (a) @@ -4109,13 +4109,13 @@ SOAP_FMAC1 int SOAP_FMAC2 soap_array_pointer_lookup(struct soap *soap, const void *p, const struct soap_array *a, int n, int type, struct soap_plist **ppp) -{ register struct soap_plist *pp; +{ struct soap_plist *pp; *ppp = NULL; if (!p || !a->__ptr) return 0; for (pp = soap->pht[soap_hash_ptr(a->__ptr)]; pp; pp = pp->next) { if (pp->type == type && pp->array && pp->array->__ptr == a->__ptr) - { register int i; + { int i; for (i = 0; i < n; i++) if (((const int*)&pp->array->__size)[i] != ((const int*)&a->__size)[i]) break; @@ -4350,7 +4350,7 @@ SOAP_FMAC1 int SOAP_FMAC2 soap_array_reference(struct soap *soap, const void *p, const struct soap_array *a, int n, int t) -{ register int i; +{ int i; struct soap_plist *pp; if (!p) return 1; @@ -4551,7 +4551,7 @@ soap_attachment(struct soap *soap, const char *tag, int id, const void *p, const #ifndef PALM_1 static void soap_init_iht(struct soap *soap) -{ register int i; +{ int i; DBGLOG(TEST, SOAP_MESSAGE(fdebug, "Initializing ID hashtable\n")); for (i = 0; i < SOAP_IDHASH; i++) soap->iht[i] = NULL; @@ -4564,9 +4564,9 @@ soap_init_iht(struct soap *soap) #ifndef PALM_1 static void soap_free_iht(struct soap *soap) -{ register int i; - register struct soap_ilist *ip, *p; - register struct soap_flist *fp, *fq; +{ int i; + struct soap_ilist *ip, *p; + struct soap_flist *fp, *fq; DBGLOG(TEST, SOAP_MESSAGE(fdebug, "Free ID hashtable\n")); for (i = 0; i < SOAP_IDHASH; i++) { for (ip = soap->iht[i]; ip; ip = p) @@ -4590,7 +4590,7 @@ SOAP_FMAC1 struct soap_ilist * SOAP_FMAC2 soap_lookup(struct soap *soap, const char *id) -{ register struct soap_ilist *ip; +{ struct soap_ilist *ip; for (ip = soap->iht[soap_hash(id)]; ip; ip = ip->next) if (!strcmp(ip->id, id)) return ip; @@ -4606,8 +4606,8 @@ SOAP_FMAC1 struct soap_ilist * SOAP_FMAC2 soap_enter(struct soap *soap, const char *id) -{ register size_t h; - register struct soap_ilist *ip; +{ size_t h; + struct soap_ilist *ip; ip = (struct soap_ilist*)SOAP_MALLOC(soap, sizeof(struct soap_ilist) + strlen(id)); if (ip) { h = soap_hash(id); @@ -4627,7 +4627,7 @@ SOAP_FMAC1 void* SOAP_FMAC2 soap_malloc(struct soap *soap, size_t n) -{ register char *p; +{ char *p; if (!n) return (void*)SOAP_NON_NULL; if (!soap) @@ -4651,7 +4651,7 @@ soap_malloc(struct soap *soap, size_t n) #ifdef SOAP_DEBUG static void soap_init_mht(struct soap *soap) -{ register int i; +{ int i; for (i = 0; i < (int)SOAP_PTRHASH; i++) soap->mht[i] = NULL; } @@ -4661,8 +4661,8 @@ soap_init_mht(struct soap *soap) #ifdef SOAP_DEBUG static void soap_free_mht(struct soap *soap) -{ register int i; - register struct soap_mlist *mp, *mq; +{ int i; + struct soap_mlist *mp, *mq; for (i = 0; i < (int)SOAP_PTRHASH; i++) { for (mp = soap->mht[i]; mp; mp = mq) { mq = mp->next; @@ -4681,10 +4681,10 @@ SOAP_FMAC1 void* SOAP_FMAC2 soap_track_malloc(struct soap *soap, const char *file, int line, size_t size) -{ register void *p = malloc(size); +{ void *p = malloc(size); if (soap) - { register int h = soap_hash_ptr(p); - register struct soap_mlist *mp = (struct soap_mlist*)malloc(sizeof(struct soap_mlist)); + { int h = soap_hash_ptr(p); + struct soap_mlist *mp = (struct soap_mlist*)malloc(sizeof(struct soap_mlist)); mp->next = soap->mht[h]; mp->ptr = p; mp->file = file; @@ -4702,8 +4702,8 @@ SOAP_FMAC1 void SOAP_FMAC2 soap_track_free(struct soap *soap, const char *file, int line, void *p) -{ register int h = soap_hash_ptr(p); - register struct soap_mlist *mp; +{ int h = soap_hash_ptr(p); + struct soap_mlist *mp; for (mp = soap->mht[h]; mp; mp = mp->next) if (mp->ptr == p) break; @@ -4724,8 +4724,8 @@ soap_track_free(struct soap *soap, const char *file, int line, void *p) #ifdef SOAP_DEBUG static void soap_track_unlink(struct soap *soap, const void *p) -{ register int h = soap_hash_ptr(p); - register struct soap_mlist *mp; +{ int h = soap_hash_ptr(p); + struct soap_mlist *mp; for (mp = soap->mht[h]; mp; mp = mp->next) if (mp->ptr == p) break; @@ -4743,7 +4743,7 @@ soap_dealloc(struct soap *soap, void *p) { if (!soap) return; if (p) - { register char **q; + { char **q; for (q = (char**)&soap->alist; *q; q = *(char***)q) { if (p == (void*)(*q - *(size_t*)(*q + sizeof(void*)))) { *q = **(char***)q; @@ -4755,7 +4755,7 @@ soap_dealloc(struct soap *soap, void *p) soap_delete(soap, p); } else - { register char *q; + { char *q; while (soap->alist) { q = (char*)soap->alist; soap->alist = *(void**)q; @@ -4783,11 +4783,11 @@ SOAP_FMAC1 void SOAP_FMAC2 soap_delete(struct soap *soap, void *p) -{ register struct soap_clist **cp = &soap->clist; +{ struct soap_clist **cp = &soap->clist; if (p) { while (*cp) { if (p == (*cp)->ptr) - { register struct soap_clist *q = *cp; + { struct soap_clist *q = *cp; *cp = q->next; q->fdelete(q); SOAP_FREE(soap, q); @@ -4799,7 +4799,7 @@ soap_delete(struct soap *soap, void *p) } else { while (*cp) - { register struct soap_clist *q = *cp; + { struct soap_clist *q = *cp; *cp = q->next; if (q->ptr == (void*)soap->fault) soap->fault = NULL; /* this was deallocated */ @@ -4818,7 +4818,7 @@ SOAP_FMAC1 struct soap_clist * SOAP_FMAC2 soap_link(struct soap *soap, void *p, int t, int n, void (*fdelete)(struct soap_clist*)) -{ register struct soap_clist *cp; +{ struct soap_clist *cp; if ((cp = (struct soap_clist*)SOAP_MALLOC(soap, sizeof(struct soap_clist)))) { cp->next = soap->clist; cp->type = t; @@ -4837,8 +4837,8 @@ SOAP_FMAC1 void SOAP_FMAC2 soap_unlink(struct soap *soap, const void *p) -{ register char **q; - register struct soap_clist **cp; +{ char **q; + struct soap_clist **cp; if (!soap || !p) return; for (q = (char**)&soap->alist; *q; q = *(char***)q) @@ -4870,7 +4870,7 @@ SOAP_FMAC1 int SOAP_FMAC2 soap_lookup_type(struct soap *soap, const char *id) -{ register struct soap_ilist *ip; +{ struct soap_ilist *ip; if (id && *id) { ip = soap_lookup(soap, id); if (ip) @@ -4996,7 +4996,7 @@ soap_id_forward(struct soap *soap, const char *href, void *p, int st, int tt, si return NULL; } if (fcopy || n < sizeof(void*) || *href != '#') - { register struct soap_flist *fp = (struct soap_flist*)SOAP_MALLOC(soap, sizeof(struct soap_flist)); + { struct soap_flist *fp = (struct soap_flist*)SOAP_MALLOC(soap, sizeof(struct soap_flist)); if (!fp) { soap->error = SOAP_EOM; return NULL; @@ -5294,10 +5294,10 @@ SOAP_FMAC1 void SOAP_FMAC2 soap_free(struct soap *soap) -{ register struct Namespace *ns; +{ struct Namespace *ns; DBGLOG(TEST, SOAP_MESSAGE(fdebug, "Free namespace stack\n")); while (soap->nlist) - { register struct soap_nlist *np = soap->nlist->next; + { struct soap_nlist *np = soap->nlist->next; if (soap->nlist->ns) SOAP_FREE(soap, soap->nlist->ns); SOAP_FREE(soap, soap->nlist); @@ -5308,7 +5308,7 @@ soap_free(struct soap *soap) soap_end_block(soap); DBGLOG(TEST, SOAP_MESSAGE(fdebug, "Free attributes\n")); while (soap->attributes) - { register struct soap_attribute *tp = soap->attributes->next; + { struct soap_attribute *tp = soap->attributes->next; if (soap->attributes->value) SOAP_FREE(soap, soap->attributes->value); SOAP_FREE(soap, soap->attributes); @@ -5458,7 +5458,7 @@ struct soap* SOAP_FMAC2 soap_copy_context(struct soap *copy, struct soap *soap) { if (copy) - { register struct soap_plugin *p; + { struct soap_plugin *p; memcpy(copy, soap, sizeof(struct soap)); copy->copy = 1; copy->user = NULL; @@ -5498,7 +5498,7 @@ soap_copy_context(struct soap *copy, struct soap *soap) #endif copy->plugins = NULL; for (p = soap->plugins; p; p = p->next) - { register struct soap_plugin *q = (struct soap_plugin*)SOAP_MALLOC(copy, sizeof(struct soap_plugin)); + { struct soap_plugin *q = (struct soap_plugin*)SOAP_MALLOC(copy, sizeof(struct soap_plugin)); if (!q) return NULL; DBGLOG(TEST, SOAP_MESSAGE(fdebug, "Copying plugin '%s'\n", p->id)); @@ -5765,7 +5765,7 @@ SOAP_FMAC1 void SOAP_FMAC2 soap_end(struct soap *soap) -{ register struct soap_clist *cp; +{ struct soap_clist *cp; soap_free(soap); soap_dealloc(soap, NULL); while (soap->clist) @@ -5789,9 +5789,9 @@ SOAP_FMAC1 int SOAP_FMAC2 soap_set_namespaces(struct soap *soap, struct Namespace *p) -{ register struct Namespace *ns = soap->local_namespaces; - register struct soap_nlist *np, *nq, *nr; - register unsigned int level = soap->level; +{ struct Namespace *ns = soap->local_namespaces; + struct soap_nlist *np, *nq, *nr; + unsigned int level = soap->level; soap->namespaces = p; soap->local_namespaces = NULL; soap_set_local_namespaces(soap); @@ -5829,7 +5829,7 @@ soap_set_namespaces(struct soap *soap, struct Namespace *p) SOAP_FREE(soap, nq); } if (ns) - { register int i; + { int i; for (i = 0; ns[i].id; i++) { if (ns[i].out) { SOAP_FREE(soap, ns[i].out); @@ -5848,9 +5848,9 @@ soap_set_namespaces(struct soap *soap, struct Namespace *p) static void soap_set_local_namespaces(struct soap *soap) { if (soap->namespaces && !soap->local_namespaces) - { register const struct Namespace *ns1; - register struct Namespace *ns2; - register size_t n = 1; + { const struct Namespace *ns1; + struct Namespace *ns2; + size_t n = 1; for (ns1 = soap->namespaces; ns1->id; ns1++) n++; n *= sizeof(struct Namespace); @@ -5880,7 +5880,7 @@ soap_element(struct soap *soap, const char *tag, int id, const char *type) /**/ #ifdef WITH_DOM if (soap->mode & SOAP_XML_DOM) - { register struct soap_dom_element *p, *e = (struct soap_dom_element*)soap_malloc(soap, sizeof(struct soap_dom_element)); + { struct soap_dom_element *p, *e = (struct soap_dom_element*)soap_malloc(soap, sizeof(struct soap_dom_element)); e->next = NULL; e->prnt = soap->dom; e->nstr = NULL; @@ -5991,7 +5991,7 @@ SOAP_FMAC1 char* SOAP_FMAC2 soap_strrchr(const char *s, int t) -{ register char *r = NULL; +{ char *r = NULL; while (*s) if (*s++ == t) r = (char*)s - 1; @@ -6007,8 +6007,8 @@ SOAP_FMAC1 long SOAP_FMAC2 soap_strtol(const char *s, char **t, int b) -{ register long n = 0; - register int c; +{ long n = 0; + int c; while (*s > 0 && *s <= 32) s++; if (b == 10) @@ -6059,7 +6059,7 @@ unsigned long SOAP_FMAC2 soap_strtoul(const char *s, char **t, int b) { unsigned long n = 0; - register int c; + int c; while (*s > 0 && *s <= 32) s++; if (b == 10) @@ -6131,13 +6131,13 @@ SOAP_FMAC1 int SOAP_FMAC2 soap_element_start_end_out(struct soap *soap, const char *tag) -{ register struct soap_attribute *tp; +{ struct soap_attribute *tp; /**/ #ifdef WITH_DOM if ((soap->mode & SOAP_XML_DOM) && soap->dom) { for (tp = soap->attributes; tp; tp = tp->next) { if (tp->visible) - { register struct soap_dom_attribute *a = (struct soap_dom_attribute*)soap_malloc(soap, sizeof(struct soap_dom_attribute)); + { struct soap_dom_attribute *a = (struct soap_dom_attribute*)soap_malloc(soap, sizeof(struct soap_dom_attribute)); a->next = soap->dom->atts; a->nstr = NULL; a->name = soap_strdup(soap, tp->name); /* check EOM */ @@ -6211,7 +6211,7 @@ SOAP_FMAC1 int SOAP_FMAC2 soap_element_ref(struct soap *soap, const char *tag, int id, int href) -{ register int n = 0; +{ int n = 0; if (soap->version == 2) n = 1; sprintf(soap->href, "#_%d", href); @@ -6322,7 +6322,7 @@ soap_attribute(struct soap *soap, const char *name, const char *value) /**/ #ifdef WITH_DOM if ((soap->mode & SOAP_XML_DOM) && soap->dom) - { register struct soap_dom_attribute *a = (struct soap_dom_attribute*)soap_malloc(soap, sizeof(struct soap_dom_attribute)); + { struct soap_dom_attribute *a = (struct soap_dom_attribute*)soap_malloc(soap, sizeof(struct soap_dom_attribute)); a->next = soap->dom->atts; a->nstr = NULL; a->name = soap_strdup(soap, name); /* check EOM */ @@ -6383,10 +6383,10 @@ SOAP_FMAC1 int SOAP_FMAC2 soap_element_end_in(struct soap *soap, const char *tag) -{ register soap_wchar c; - register char *s; - register const char *t; - register int n = 0; +{ soap_wchar c; + char *s; + const char *t; + int n = 0; if (tag && *tag == '-') return SOAP_OK; soap->level--; @@ -6449,7 +6449,7 @@ SOAP_FMAC1 const char * SOAP_FMAC2 soap_attr_value(struct soap *soap, const char *name, int flag) -{ register struct soap_attribute *tp; +{ struct soap_attribute *tp; for (tp = soap->attributes; tp; tp = tp->next) if (!soap_match_tag(soap, tp->name, name)) break; @@ -6471,7 +6471,7 @@ SOAP_FMAC1 int SOAP_FMAC2 soap_set_attr(struct soap *soap, const char *name, const char *value) -{ register struct soap_attribute *tp; +{ struct soap_attribute *tp; DBGLOG(TEST, SOAP_MESSAGE(fdebug, "Set attribute %s='%s'\n", name, value?value:"")); for (tp = soap->attributes; tp; tp = tp->next) if (!strcmp(tp->name, name)) @@ -6549,7 +6549,7 @@ SOAP_FMAC1 void SOAP_FMAC2 soap_clr_attr(struct soap *soap) -{ register struct soap_attribute *tp; +{ struct soap_attribute *tp; #ifndef WITH_LEAN if (soap->mode & SOAP_XML_CANONICAL) { while (soap->attributes) @@ -6632,7 +6632,7 @@ soap_getattrval(struct soap *soap, char *s, size_t n, soap_wchar d) static int soap_append_lab(struct soap *soap, const char *s, size_t n) { if (soap->labidx + n >= soap->lablen) - { register char *t = soap->labbuf; + { char *t = soap->labbuf; DBGLOG(TEST, SOAP_MESSAGE(fdebug, "Enlarging look-aside buffer to append data, old size=%lu", (unsigned long)soap->lablen)); if (soap->lablen == 0) soap->lablen = SOAP_LABLEN; @@ -6665,11 +6665,11 @@ SOAP_FMAC1 int SOAP_FMAC2 soap_peek_element(struct soap *soap) -{ register struct soap_attribute *tp; +{ struct soap_attribute *tp; const char *t; - register char *s; - register soap_wchar c; - register int i; + char *s; + soap_wchar c; + int i; if (soap->peeked) { if (!*soap->tag) return soap->error = SOAP_NO_TAG; @@ -6955,9 +6955,9 @@ SOAP_FMAC1 int SOAP_FMAC2 soap_string_out(struct soap *soap, const char *s, int flag) -{ register const char *t; - register soap_wchar c; - register soap_wchar mask = 0xFFFFFF80UL; +{ const char *t; + soap_wchar c; + soap_wchar mask = 0xFFFFFF80UL; #ifdef WITH_DOM if ((soap->mode & SOAP_XML_DOM) && soap->dom) { soap->dom->data = soap_strdup(soap, s); /* check EOM */ @@ -7018,7 +7018,7 @@ soap_string_out(struct soap *soap, const char *s, int flag) #ifdef HAVE_MBTOWC if (soap->mode & SOAP_C_MBSTRING) { wchar_t wc; - register int m = mbtowc(&wc, t - 1, MB_CUR_MAX); + int m = mbtowc(&wc, t - 1, MB_CUR_MAX); if (m > 0 && wc != c) { if (soap_send_raw(soap, s, t - s - 1) || soap_pututf8(soap, wc)) return soap->error; @@ -7045,13 +7045,13 @@ SOAP_FMAC1 char * SOAP_FMAC2 soap_string_in(struct soap *soap, int flag, long minlen, long maxlen) -{ register char *s; +{ char *s; char *t = NULL; - register size_t i; - register long l = 0; - register int n = 0; - register int m = 0; - register soap_wchar c; + size_t i; + long l = 0; + int n = 0; + int m = 0; + soap_wchar c; #if !defined(WITH_LEANER) && defined(HAVE_WCTOMB) char buf[MB_LEN_MAX > 8 ? MB_LEN_MAX : 8]; #else @@ -7060,7 +7060,7 @@ soap_string_in(struct soap *soap, int flag, long minlen, long maxlen) DBGLOG(TEST,SOAP_MESSAGE(fdebug, "Reading string content\n")); #ifdef WITH_CDATA if (!flag) - { register int state = 0; + { int state = 0; #ifdef WITH_FAST soap->labidx = 0; /* use look-aside buffer */ #else @@ -7070,14 +7070,14 @@ soap_string_in(struct soap *soap, int flag, long minlen, long maxlen) for (;;) { #ifdef WITH_FAST - register size_t k; + size_t k; if (soap_append_lab(soap, NULL, 0)) /* allocate more space in look-aside buffer if necessary */ return NULL; s = soap->labbuf + soap->labidx; /* space to populate */ k = soap->lablen - soap->labidx; /* number of bytes available */ soap->labidx = soap->lablen; /* claim this space */ #else - register size_t k = SOAP_BLKLEN; + size_t k = SOAP_BLKLEN; if (!(s = (char*)soap_push_block(soap, k))) return NULL; #endif @@ -7279,14 +7279,14 @@ soap_string_in(struct soap *soap, int flag, long minlen, long maxlen) for (;;) { #ifdef WITH_FAST - register size_t k; + size_t k; if (soap_append_lab(soap, NULL, 0)) /* allocate more space in look-aside buffer if necessary */ return NULL; s = soap->labbuf + soap->labidx; /* space to populate */ k = soap->lablen - soap->labidx; /* number of bytes available */ soap->labidx = soap->lablen; /* claim this space */ #else - register size_t k = SOAP_BLKLEN; + size_t k = SOAP_BLKLEN; if (!(s = (char*)soap_push_block(soap, k))) return NULL; #endif @@ -7472,7 +7472,7 @@ SOAP_FMAC2 soap_wstring_out(struct soap *soap, const wchar_t *s, int flag) { const char *t; char tmp; - register soap_wchar c; + soap_wchar c; #ifdef WITH_DOM if ((soap->mode & SOAP_XML_DOM) && soap->dom) { soap->dom->wide = NULL; /* soap_malloc() ??? */ @@ -7541,9 +7541,9 @@ wchar_t * SOAP_FMAC2 soap_wstring_in(struct soap *soap, int flag, long minlen, long maxlen) { wchar_t *s; - register int i, n = 0; - register long l = 0; - register soap_wchar c; + int i, n = 0; + long l = 0; + soap_wchar c; const char *t = NULL; DBGLOG(TEST,SOAP_MESSAGE(fdebug, "Reading wide string content\n")); if (soap->peeked && *soap->tag) @@ -8652,7 +8652,7 @@ soap_s2TQName(struct soap *soap, const char *s, char **t) np = soap->nlist; p = strchr(s, ':'); if (p) - { register int n = p - s; + { int n = p - s; while (np && (strncmp(np->id, s, n) || np->id[n])) np = np->next; p++; @@ -8664,7 +8664,7 @@ soap_s2TQName(struct soap *soap, const char *s, char **t) } if (np) { if (np->index >= 0 && soap->local_namespaces) - { register const char *q = soap->local_namespaces[np->index].id; + { const char *q = soap->local_namespaces[np->index].id; if (q) { if ((*t = (char*)soap_malloc(soap, strlen(p) + strlen(q) + 2))) sprintf(*t, "%s:%s", q, p); @@ -9191,9 +9191,9 @@ SOAP_FMAC1 const char * SOAP_FMAC2 soap_token(struct soap *soap) -{ register size_t i; - register soap_wchar c = 0; - register char *s = soap->tmpbuf; +{ size_t i; + soap_wchar c = 0; + char *s = soap->tmpbuf; if (!soap->body) return SOAP_STR_EOS; do c = soap_get(soap); @@ -9218,9 +9218,9 @@ SOAP_FMAC1 const char * SOAP_FMAC2 soap_value(struct soap *soap) -{ register size_t i; - register soap_wchar c = 0; - register char *s = soap->tmpbuf; +{ size_t i; + soap_wchar c = 0; + char *s = soap->tmpbuf; if (!soap->body) return SOAP_STR_EOS; do c = soap_get(soap); @@ -9284,8 +9284,8 @@ static size_t soap_count_attachments(struct soap *soap) { #ifndef WITH_LEANER - register struct soap_multipart *content; - register size_t count = soap->count; + struct soap_multipart *content; + size_t count = soap->count; DBGLOG(TEST, SOAP_MESSAGE(fdebug, "Calculating the message size with attachments, current count=%lu\n", count)); if ((soap->mode & SOAP_ENC_DIME) && !(soap->mode & SOAP_ENC_MTOM)) { DBGLOG(TEST, SOAP_MESSAGE(fdebug, "Calculating the size of DIME attachments\n")); @@ -9301,10 +9301,10 @@ soap_count_attachments(struct soap *soap) } } if ((soap->mode & SOAP_ENC_MIME) && soap->mime.boundary) - { register size_t n = strlen(soap->mime.boundary); + { size_t n = strlen(soap->mime.boundary); DBGLOG(TEST, SOAP_MESSAGE(fdebug, "Calculating the size of MIME attachments\n")); for (content = soap->mime.first; content; content = content->next) - { register const char *s; + { const char *s; /* count \r\n--boundary\r\n */ count += 6 + n; /* count Content-Type: ...\r\n */ @@ -9506,9 +9506,9 @@ soap_putdime(struct soap *soap) #ifndef PALM_1 static char * soap_getdimefield(struct soap *soap, size_t n) -{ register soap_wchar c; - register int i; - register char *s; +{ soap_wchar c; + int i; + char *s; char *p = NULL; if (n) { p = (char*)soap_malloc(soap, n + 1); @@ -9540,9 +9540,9 @@ SOAP_FMAC1 int SOAP_FMAC2 soap_getdimehdr(struct soap *soap) -{ register soap_wchar c; - register char *s; - register int i; +{ soap_wchar c; + char *s; + int i; unsigned char tmp[12]; size_t optlen, idlen, typelen; if (!(soap->mode & SOAP_ENC_DIME)) @@ -9599,7 +9599,7 @@ soap_getdime(struct soap *soap) if (soap_move(soap, ((soap->dime.size+3)&(~3))-soap_tell(soap))) return soap->error = SOAP_EOF; for (;;) - { register struct soap_multipart *content; + { struct soap_multipart *content; if (soap_getdimehdr(soap)) break; if (soap->fdimewriteopen && ((soap->dime.ptr = (char*)soap->fdimewriteopen(soap, soap->dime.id, soap->dime.type, soap->dime.options)) || soap->error)) @@ -9647,9 +9647,9 @@ end: } else if (soap->dime.flags & SOAP_DIME_CF) { const char *id, *type, *options; - register soap_wchar c; - register char *s; - register int i; + soap_wchar c; + char *s; + int i; id = soap->dime.id; type = soap->dime.type; options = soap->dime.options; @@ -9730,8 +9730,8 @@ soap_getmimehdr(struct soap *soap) return soap->error = SOAP_EOM; content = soap->mime.last; for (;;) - { register char *key = soap->msgbuf; - register char *val; + { char *key = soap->msgbuf; + char *val; if (!*key) break; DBGLOG(TEST,SOAP_MESSAGE(fdebug, "MIME header: %s\n", key)); @@ -9768,12 +9768,12 @@ SOAP_FMAC1 int SOAP_FMAC2 soap_getmime(struct soap *soap) -{ register soap_wchar c; +{ soap_wchar c; if (!soap->mime.last) return SOAP_OK; for (;;) - { register size_t i, m = 0; - register char *s, *t = NULL; + { size_t i, m = 0; + char *s, *t = NULL; struct soap_multipart *content = soap->mime.last; DBGLOG(TEST, SOAP_MESSAGE(fdebug, "Parsing MIME content id=%s type=%s\n", content->id?content->id:"", content->type?content->type:"")); if (soap_new_block(soap)) @@ -9841,7 +9841,7 @@ end: #ifndef PALM_1 static int soap_match_cid(const char *s, const char *t) -{ register size_t n; +{ size_t n; if (!s) return 1; if (!strcmp(s, t)) @@ -9866,10 +9866,10 @@ soap_match_cid(const char *s, const char *t) static void soap_resolve_attachment(struct soap *soap, struct soap_multipart *content) { if (content->id) - { register struct soap_xlist **xp = &soap->xlist; + { struct soap_xlist **xp = &soap->xlist; DBGLOG(TEST, SOAP_MESSAGE(fdebug, "Resolving attachment data for id=%s\n", content->id)); while (*xp) - { register struct soap_xlist *xq = *xp; + { struct soap_xlist *xq = *xp; if (!soap_match_cid(xq->id, content->id)) { DBGLOG(TEST, SOAP_MESSAGE(fdebug, "Found matching attachment %s for content id=%s\n", xq->id, content->id)); *xp = xq->next; @@ -10083,8 +10083,8 @@ soap_next_multipart(struct soap_multipart *content) static void soap_select_mime_boundary(struct soap *soap) { while (!soap->mime.boundary || soap_valid_mime_boundary(soap)) - { register char *s = soap->mime.boundary; - register size_t n = 0; + { char *s = soap->mime.boundary; + size_t n = 0; if (s) n = strlen(s); if (n < 16) @@ -10113,12 +10113,12 @@ soap_select_mime_boundary(struct soap *soap) #ifndef PALM_1 static int soap_valid_mime_boundary(struct soap *soap) -{ register struct soap_multipart *content; - register size_t k = strlen(soap->mime.boundary); +{ struct soap_multipart *content; + size_t k = strlen(soap->mime.boundary); for (content = soap->mime.first; content; content = content->next) { if (content->ptr && content->size >= k) - { register const char *p = (const char*)content->ptr; - register size_t i; + { const char *p = (const char*)content->ptr; + size_t i; for (i = 0; i < content->size - k; i++, p++) if (!strncmp(p, soap->mime.boundary, k)) return SOAP_ERR; @@ -10137,8 +10137,8 @@ SOAP_FMAC1 size_t SOAP_FMAC2 soap_encode_cookie(const char *s, char *t, size_t len) -{ register int c; - register size_t n = len; +{ int c; + size_t n = len; while ((c = *s++) && --n > 0) { if (c > ' ' && c < 128 && !strchr("()<>@,;:\\\"/[]?={}", c)) *t++ = c; @@ -11161,10 +11161,10 @@ SOAP_FMAC1 const char* SOAP_FMAC2 soap_get_header_attribute(struct soap *soap, const char *line, const char *key) -{ register const char *s = line; +{ const char *s = line; if (s) { while (*s) - { register short flag; + { short flag; s = soap_decode_key(soap->tmpbuf, sizeof(soap->tmpbuf), s); flag = soap_tag_cmp(soap->tmpbuf, key); s = soap_decode_val(soap->tmpbuf, sizeof(soap->tmpbuf), s); @@ -11312,7 +11312,7 @@ SOAP_FMAC1 int SOAP_FMAC2 soap_envelope_begin_in(struct soap *soap) -{ register struct Namespace *p; +{ struct Namespace *p; soap->part = SOAP_IN_ENVELOPE; if (soap_element_begin_in(soap, "SOAP-ENV:Envelope", 0)) return soap->error = SOAP_VERSIONMISMATCH; @@ -11431,8 +11431,8 @@ SOAP_FMAC1 void SOAP_FMAC2 soap_set_endpoint(struct soap *soap, const char *endpoint) -{ register const char *s; - register size_t i, n; +{ const char *s; + size_t i, n; soap->endpoint[0] = '\0'; soap->host[0] = '\0'; soap->path[0] = '/'; @@ -11572,9 +11572,9 @@ SOAP_FMAC1 char* SOAP_FMAC2 soap_s2base64(struct soap *soap, const unsigned char *s, char *t, size_t n) -{ register size_t i; - register unsigned long m; - register char *p; +{ size_t i; + unsigned long m; + char *p; if (!t) t = (char*)soap_malloc(soap, (n + 2) / 3 * 4 + 1); if (!t) @@ -11616,9 +11616,9 @@ SOAP_FMAC1 const char* SOAP_FMAC2 soap_base642s(struct soap *soap, const char *s, char *t, size_t l, int *n) -{ register int i, j, c; - register unsigned long m; - register const char *p; +{ int i, j, c; + unsigned long m; + const char *p; if (!t) { l = (strlen(s) + 3) / 4 * 3; t = (char*)soap_malloc(soap, l); @@ -11680,7 +11680,7 @@ SOAP_FMAC1 char* SOAP_FMAC2 soap_s2hex(struct soap *soap, const unsigned char *s, char *t, size_t n) -{ register char *p; +{ char *p; if (!t) t = (char*)soap_malloc(soap, 2 * n + 1); if (!t) @@ -11691,7 +11691,7 @@ soap_s2hex(struct soap *soap, const unsigned char *s, char *t, size_t n) t[0] = '\0'; if (s) { for (; n > 0; n--) - { register int m = *s++; + { int m = *s++; *t++ = (char)((m >> 4) + (m > 159 ? 'a' - 10 : '0')); m &= 0x0F; *t++ = (char)(m + (m > 9 ? 'a' - 10 : '0')); @@ -11708,7 +11708,7 @@ SOAP_FMAC1 const char* SOAP_FMAC2 soap_hex2s(struct soap *soap, const char *s, char *t, size_t l, int *n) -{ register const char *p; +{ const char *p; if (!t) { l = strlen(s) / 2; t = (char*)soap_malloc(soap, l); @@ -11719,8 +11719,8 @@ soap_hex2s(struct soap *soap, const char *s, char *t, size_t l, int *n) } p = t; while (l > 1) - { register int d1 = *s++; - register int d2 = *s++; + { int d1 = *s++; + int d2 = *s++; *t++ = ((d1 >= 'A' ? (d1 & 0x7) + 9 : d1 - '0') << 4) + (d2 >= 'A' ? (d2 & 0x7) + 9 : d2 - '0'); l -= 2; } @@ -11737,11 +11737,11 @@ SOAP_FMAC1 int SOAP_FMAC2 soap_puthttphdr(struct soap *soap, int status, size_t count) -{ register const char *s; +{ const char *s; #ifndef WITH_LEANER - register const char *r = NULL; + const char *r = NULL; #endif - register int err; + int err; if (status == SOAP_FILE && soap->http_content) s = soap->http_content; else if (status == SOAP_HTML) @@ -11760,7 +11760,7 @@ soap_puthttphdr(struct soap *soap, int status, size_t count) s = "application/dime"; } if ((soap->mode & SOAP_ENC_MIME) && soap->mime.boundary && soap->status != SOAP_GET) - { register const char *t = strchr(s, ';'); + { const char *t = strchr(s, ';'); sprintf(soap->tmpbuf, "multipart/related; boundary=\"%s\"; type=\"", soap->mime.boundary); if (t) strncat(soap->tmpbuf, s, t - s); @@ -11824,8 +11824,8 @@ http_get(struct soap *soap) #ifndef PALM_1 static int http_post(struct soap *soap, const char *endpoint, const char *host, int port, const char *path, const char *action, size_t count) -{ register const char *s; - register int err; +{ const char *s; + int err; if (soap->status == SOAP_GET) { s = "GET"; count = 0; @@ -11900,7 +11900,7 @@ http_post(struct soap *soap, const char *endpoint, const char *host, int port, c #ifndef PALM_1 static int http_send_header(struct soap *soap, const char *s) -{ register const char *t; +{ const char *t; do { t = strchr(s, '\n'); /* disallow \n in HTTP headers */ if (!t) @@ -11935,7 +11935,7 @@ http_post_header(struct soap *soap, const char *key, const char *val) #ifndef PALM_1 static int http_response(struct soap *soap, int status, size_t count) -{ register int err; +{ int err; #ifdef WMW_RPM_IO if (soap->rpmreqid) httpOutputEnable(soap->rpmreqid); @@ -12007,7 +12007,7 @@ SOAP_FMAC1 int SOAP_FMAC2 soap_response(struct soap *soap, int status) -{ register size_t count; +{ size_t count; if (!(soap->omode & (SOAP_ENC_XML | SOAP_IO_STORE /* this tests for chunking too */)) && (status == SOAP_HTML || status == SOAP_FILE)) { soap->omode &= ~SOAP_IO; @@ -12019,7 +12019,7 @@ soap_response(struct soap *soap, int status) return soap->error; #ifndef WITH_NOHTTP if ((soap->mode & SOAP_IO) != SOAP_IO_STORE && !(soap->mode & SOAP_ENC_XML)) - { register int n = soap->mode; + { int n = soap->mode; soap->mode &= ~(SOAP_IO | SOAP_ENC_ZLIB); if ((n & SOAP_IO) != SOAP_IO_FLUSH) soap->mode |= SOAP_IO_BUFFER; @@ -12233,7 +12233,7 @@ SOAP_FMAC1 int SOAP_FMAC2 soap_send_fault(struct soap *soap) -{ register int status = soap->error; +{ int status = soap->error; int r = 1; if (status == SOAP_STOP) return status; @@ -12295,7 +12295,7 @@ SOAP_FMAC1 int SOAP_FMAC2 soap_recv_fault(struct soap *soap) -{ register int status = soap->error; +{ int status = soap->error; DBGLOG(TEST,SOAP_MESSAGE(fdebug, "Receiving SOAP Fault\n")); soap->error = SOAP_OK; if (soap_getfault(soap)) @@ -12305,7 +12305,7 @@ soap_recv_fault(struct soap *soap) soap_set_fault(soap); } else - { register const char *s = *soap_faultcode(soap); + { const char *s = *soap_faultcode(soap); if (!soap_match_tag(soap, s, "SOAP-ENV:Server") || !soap_match_tag(soap, s, "SOAP-ENV:Receiver")) status = SOAP_SVR_FAULT; else if (!soap_match_tag(soap, s, "SOAP-ENV:Client") || !soap_match_tag(soap, s, "SOAP-ENV:Sender")) @@ -12362,7 +12362,7 @@ soap_recv_empty_response(struct soap *soap) #ifndef PALM_1 static const char* soap_strerror(struct soap *soap) -{ register int err = soap->errnum; +{ int err = soap->errnum; if (err) { #ifndef WIN32 @@ -12384,7 +12384,7 @@ soap_set_error(struct soap *soap, const char *faultcode, const char *faultstring { *soap_faultcode(soap) = faultcode; *soap_faultstring(soap) = faultstring; if (faultdetail && *faultdetail) - { register const char **s = soap_faultdetail(soap); + { const char **s = soap_faultdetail(soap); if (s) *s = faultdetail; } @@ -12504,8 +12504,8 @@ SOAP_FMAC1 int SOAP_FMAC2 soap_register_plugin_arg(struct soap *soap, int (*fcreate)(struct soap*, struct soap_plugin*, void*), void *arg) -{ register struct soap_plugin *p; - register int r; +{ struct soap_plugin *p; + int r; if (!(p = (struct soap_plugin*)SOAP_MALLOC(soap, sizeof(struct soap_plugin)))) return soap->error = SOAP_EOM; p->id = NULL; @@ -12529,7 +12529,7 @@ soap_register_plugin_arg(struct soap *soap, int (*fcreate)(struct soap*, struct #ifndef PALM_1 static void * fplugin(struct soap *soap, const char *id) -{ register struct soap_plugin *p; +{ struct soap_plugin *p; for (p = soap->plugins; p; p = p->next) if (p->id == id || !strcmp(p->id, id)) return p->data; |