[Top][All Lists]

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

[libmicrohttpd] ITALY - memory pool (2)

From: address@hidden
Subject: [libmicrohttpd] ITALY - memory pool (2)
Date: Wed, 15 Sep 2010 17:39:41 +0200 (CEST)

Hi Christian,

 I read all the files of the trunk and indeed noticed that the malloc() 
function is called quite a few times.

I read your suggestion and I think that's a good point to start.

I see here a 2-step job.

First step: I want to compile and build MHD with MSVC without the GCC/Cygwin 
layer and have MHD running on Windows directly.

Second step: I have to port the MHD library on a generic embedded platform.  
What I would do is:

 - Replace all the POSIX calls in the code with function pointers

 - Write an MHD_config (mhd_conf_t  *conf) function, where the caller passes 
the address of the actual function

In this way the code can be compiled on any platform/compiler and we leave the 
end user to implement the actual functions.
In principle, one can replace the TCP/IP stack with a RS232 stack as a 
transport layer.

That's the way I did it when I ported the FreeDOS FAT 16 filesystem.

I see here also another smaller problem: the ordinary Windows user doesn't 
know how to build the code with Cygwin.
I would add a separate project file for MSVC.

What do you think?


reply via email to

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