libmicrohttpd
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[libmicrohttpd] Problems with parsing POST data


From: Peter Ross
Subject: [libmicrohttpd] Problems with parsing POST data
Date: Fri, 13 Mar 2009 22:13:14 +1100
User-agent: Mutt/1.5.18 (2008-05-17)

Hi,

I am using libmicrohttpd to parse POST x-www-form-urlencoded data.
Ocassionally I observe a "problem" whereby POST data is sent by the
webbrowser (confirmed using wireshark), but the POST data is not being
parsed by libmicrohttpd.

Diagnosis: It appears that upon accepting the client's connection, the
first call libmicrohttpd makes to TCP/IP recv() returns the complete HTTP
header, but not the subsequent POST data. This causes the connection handler/
callback function to be invoked with *upload_data_size=0, however
connection->remaining_upload_size is set to the Content-Length length
(which equates to the number of yet-to-be-received POST data).

When MHD_post_process() is later called with *upload_data_size, the 
function considers there to be no POST data to parse, and returns immediately.

Is this a bug, missing feature, or am I doing something wrong?

Cheers,

-- Peter
(A907 E02F A6E5 0CD2 34CD 20D2 6760 79C5 AC40 DD6B)

Attachment: signature.asc
Description: Digital signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]