Changeset 453


Ignore:
Timestamp:
May 17, 2006 9:24:14 PM (17 years ago)
Author:
bennylp
Message:

Changed the way Content-Type is written. Whitespace is now written before the number because some UAs are protesting otherwise

File:
1 edited

Legend:

Unmodified
Added
Removed
  • pjproject/trunk/pjsip/src/pjsip/sip_msg.c

    r315 r453  
    365365    /* Process message body. */ 
    366366    if (msg->body) { 
     367        enum { CLEN_SPACE = 12 }; 
    367368        char *clen_pos = NULL; 
    368369 
     
    397398             * body. 
    398399             */ 
    399             pj_memset(p, ' ', 12); 
     400            pj_memset(p, ' ', CLEN_SPACE); 
    400401            clen_pos = p; 
    401             p += 12; 
     402            p += CLEN_SPACE; 
    402403            *p++ = '\r'; 
    403404            *p++ = '\n'; 
     
    419420         */ 
    420421        if (clen_pos) { 
    421             len = pj_utoa(len, clen_pos); 
    422             clen_pos[len] = ' '; 
     422            char tmp[CLEN_SPACE]; 
     423            len = pj_utoa(len, tmp); 
     424            pj_memcpy(clen_pos+CLEN_SPACE-len, tmp, len); 
    423425        } 
    424426 
Note: See TracChangeset for help on using the changeset viewer.