Peter Higginson wrote:
> Martin,
>
> The original code that I submitted for this had %4u - which I think would be
> better than %4d although in practice it would not matter.
>
> The definition of "z" in %4zu is: "A following integer conversion
> corresponds to a size_t or ssize_t argument". AFAIK this is technically
> correct for the result of pointer arithmetic.
>
> My guess is that you have a compiler that does not support the z option.
>   
Apparently so, gcc 3.4.6 on Solaris 8, everything is find on Linux x86 
gcc 4.1.2.
> I don't know where we go from here; my other assumption is that someone with
> a 64 bit system needed the z to correctly print the result of pointer
> arithmetic (or to get rid of some warning).
>
> My suggestion is to leave the %4zu. If you want to suggest some conditional
> compilation I would support that.
>   
I'll try to figure out something.

Thanks,
Martin
> Peter
>
> -----Original Message-----
> From: [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED] On Behalf Of
> M.H.VanLeeuwen
> Sent: 09 May 2007 06:03
> To: [email protected]
> Subject: [Sipp-users] Content Length problem, possible fix.
>
> Hi,
>
> "Content Length: zu" seems to be generated from %4zu, changed to %4d in the
> following patch to fix the problem.
>
> Martin
>
> --- call.cpp.orig       2007-05-02 17:28:48.336760000 -0500
> +++ call.cpp    2007-05-08 23:53:58.001734000 -0500
> @@ -2382,7 +2383,7 @@
>         key = strstr(length_marker,"\r\n\r\n");
>         if (key && dest - key > 4 && dest - key < 10004) {
>           char tmp = length_marker[4];
> -        sprintf(length_marker, "%4zu", dest - key - 4 + len_offset);
> +        sprintf(length_marker, "%4d", dest - key - 4 + len_offset);
>           length_marker[4] = tmp;
>         } else {
>           // Other cases: Content-Length is 0
>
> -------------------------------------------------------------------------
> This SF.net email is sponsored by DB2 Express
> Download DB2 Express C - the FREE version of DB2 express and take
> control of your XML. No limits. Just data. Click to get it now.
> http://sourceforge.net/powerbar/db2/
> _______________________________________________
> Sipp-users mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/sipp-users
>
>
>
>
>
> ---------------------------------------------------------------------------------------------
> This e-mail may contain confidential and/or privileged information.
> If you are not the intended recipient (or have received this e-mail in error) 
> please
> notify the sender immediately and delete this e-mail. Any unauthorized 
> copying,
> disclosure or distribution of the contents in this e-mail is strictly 
> forbidden.
> ---------------------------------------------------------------------------------------------
> Newport Networks Limited is registered in England. Registration number 
> 4067591.
> Registered office: 6 St. Andrew Street, London EC4A 3LX
> ---------------------------------------------------------------------------------------------
>
>   


-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Sipp-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/sipp-users

Reply via email to