Hi, if a UDP response has no "Content-Length" header (so it's 0), which would be the value of $cl variable? This is, if I do:
if ( $cl != 0 ) ...
will this "if" match when the message has no "Content-Length" header?
Another question: In case "Content-Lenght: 22" but the real message body is 33, which value will $cl report?
Thanks.
Hello,
On 05/27/2009 12:43 PM, Iñaki Baz Castillo wrote:
Hi, if a UDP response has no "Content-Length" header (so it's 0), which would be the value of $cl variable?
if the header is missing, the value is set to null. Maybe is better to be 0.
This is, if I do:
if ( $cl != 0 ) ...
will this "if" match when the message has no "Content-Length" header?
Another question: In case "Content-Lenght: 22" but the real message body is 33, which value will $cl report?
the value is taken from header. Basically $cl is more or less an alias to $hdr(Content-Lenght).
I see a need for one PV returning the real size of the content rather than content of the CL header.
Cheers, Daniel
2009/5/27 Daniel-Constantin Mierla miconda@gmail.com:
Hello,
On 05/27/2009 12:43 PM, Iñaki Baz Castillo wrote:
Hi, if a UDP response has no "Content-Length" header (so it's 0), which would be the value of $cl variable?
if the header is missing, the value is set to null. Maybe is better to be 0.
This is, if I do:
if ( $cl != 0 ) ...
will this "if" match when the message has no "Content-Length" header?
Another question: In case "Content-Lenght: 22" but the real message body is 33, which value will $cl report?
the value is taken from header. Basically $cl is more or less an alias to $hdr(Content-Lenght).
I see a need for one PV returning the real size of the content rather than content of the CL header.
Yes, it would be really better than taking the Content-Length valur :)
Hello,
On 05/27/2009 03:43 PM, Iñaki Baz Castillo wrote:
2009/5/27 Daniel-Constantin Mierla miconda@gmail.com:
Hello,
On 05/27/2009 12:43 PM, Iñaki Baz Castillo wrote:
Hi, if a UDP response has no "Content-Length" header (so it's 0), which would be the value of $cl variable?
if the header is missing, the value is set to null. Maybe is better to be 0.
This is, if I do:
if ( $cl != 0 ) ...
will this "if" match when the message has no "Content-Length" header?
Another question: In case "Content-Lenght: 22" but the real message body is 33, which value will $cl report?
the value is taken from header. Basically $cl is more or less an alias to $hdr(Content-Lenght).
I see a need for one PV returning the real size of the content rather than content of the CL header.
Yes, it would be really better than taking the Content-Length valur :)
added to sip router the $bs - body size - which does not care about CL header.
Cheers, Daniel
2009/6/3 Daniel-Constantin Mierla miconda@gmail.com:
added to sip router the $bs - body size - which does not care about CL header.
Thanks :)