Thread overview | |||||
---|---|---|---|---|---|
|
November 15, 2011 FastCGI | ||||
---|---|---|---|---|
| ||||
Dear, I have do a wrapper for FastCGI: git@github.com:bioinfornatics/DFastCGI.git i have already see other project like: - adam rupe https://github.com/adamdruppe/misc-stuff-including-D-programming-language-web-stuff - mrmonday: https://github.com/mrmonday/serenity.git DFastCGI is just a wrapper for fastcgi fcgiapp seem works but not fcgi_stdio, any help are welcome in more i have a question how translate this C code to D: ------------------------------------------------------------------------- typedef struct FCGX_Request { int requestId; /* valid if isBeginProcessed */ int role; FCGX_Stream *in; FCGX_Stream *out; FCGX_Stream *err; char **envp; /* Don't use anything below here */ struct Params *paramsPtr; int ipcFd; /* < 0 means no connection */ int isBeginProcessed; /* FCGI_BEGIN_REQUEST seen */ int keepConnection; /* don't close ipcFd at end of request */ int appStatus; int nWriters; /* number of open writers (0..2) */ int flags; int listen_sock; } FCGX_Request; ------------------------------------------------------------------------- This struct use in keyword as member for this struct! so i am not sure if this is correct: ------------------------------------------------------------------------- struct FCGX_Request { int requestId; /* valid if isBeginProcessed */ int role; FCGX_Stream* streamIn; FCGX_Stream* streamOut; FCGX_Stream* streamErr; char** envp; /* Don't use anything below here */ //~ struct Params* paramsPtr; // where is define Params ? int ipcFd; /* < 0 means no connection */ int isBeginProcessed; /* FCGI_BEGIN_REQUEST seen */ int keepConnection; /* don't close ipcFd at end of request */ int appStatus; int nWriters; /* number of open writers (0..2) */ int flags; int listen_sock; } ------------------------------------------------------------------------- Kind regards |
November 15, 2011 Re: FastCGI | ||||
---|---|---|---|---|
| ||||
Posted in reply to bioinfornatics | On 15/11/2011 18:30, bioinfornatics wrote: > Dear, > I have do a wrapper for FastCGI: > git@github.com:bioinfornatics/DFastCGI.git > > i have already see other project like: > - adam rupe > https://github.com/adamdruppe/misc-stuff-including-D-programming-language-web-stuff > > - mrmonday: https://github.com/mrmonday/serenity.git > > DFastCGI is just a wrapper for fastcgi fcgiapp seem works but not > fcgi_stdio, any help are welcome > > in more i have a question how translate this C code to D: > ------------------------------------------------------------------------- > typedef struct FCGX_Request { > int requestId; /* valid if isBeginProcessed */ > int role; > FCGX_Stream *in; > FCGX_Stream *out; > FCGX_Stream *err; > char **envp; > > /* Don't use anything below here */ > > struct Params *paramsPtr; > int ipcFd; /*< 0 means no connection */ > int isBeginProcessed; /* FCGI_BEGIN_REQUEST seen */ > int keepConnection; /* don't close ipcFd at end of request */ > int appStatus; > int nWriters; /* number of open writers (0..2) */ > int flags; > int listen_sock; > } FCGX_Request; > ------------------------------------------------------------------------- > This struct use in keyword as member for this struct! > so i am not sure if this is correct: > ------------------------------------------------------------------------- > > struct FCGX_Request { > int requestId; /* valid if isBeginProcessed */ > int role; > FCGX_Stream* streamIn; > FCGX_Stream* streamOut; > FCGX_Stream* streamErr; > char** envp; > > /* Don't use anything below here */ > > //~ struct Params* paramsPtr; // where is define Params ? > int ipcFd; /*< 0 means no connection */ > int isBeginProcessed; /* FCGI_BEGIN_REQUEST seen */ > int keepConnection; /* don't close ipcFd at end of request > */ > int appStatus; > int nWriters; /* number of open writers (0..2) */ > int flags; > int listen_sock; > } > ------------------------------------------------------------------------- > > > Kind regards > FYI This should really be posted on D.learn. The name of the members does not matter, only the size and order (and linkage of course), you can name them whatever you like. -- Robert (aka mrmonday) http://octarineparrot.com/ |
December 13, 2011 Re: FastCGI | ||||
---|---|---|---|---|
| ||||
Posted in reply to Robert Clipsham | > On 15/11/2011 18:30, bioinfornatics wrote:
>> I have do a wrapper for FastCGI:
It would be really neat if you could move it to deimos. I'd like to participate.
|
Copyright © 1999-2021 by the D Language Foundation