Exemplo n.º 1
0
int FCGI_vprintf(const char *format, va_list ap)
{
    if(FCGI_stdout->stdio_stream)
        return vfprintf(FCGI_stdout->stdio_stream, format, ap);
    else if(FCGI_stdout->fcgx_stream) 
        return FCGX_VFPrintF(FCGI_stdout->fcgx_stream, format, ap);
    return EOF;
}
Exemplo n.º 2
0
int FCGI_vfprintf(FCGI_FILE *fp, const char *format, va_list ap)
{
    if(fp->stdio_stream)
        return vfprintf(fp->stdio_stream, format, ap);
    else if(fp->fcgx_stream) 
        return FCGX_VFPrintF(fp->fcgx_stream, format, ap);
    return EOF;
}
int HttpResponseX::Printf(const char * format, ...)
{
    int result;
    va_list args;
    va_start(args, format);
    result = FCGX_VFPrintF(request_->GetFCGX_Request()->out, format, args);
    va_end(args);
    return result;
}
int HttpResponseX::Write(const char * fmt, ...)
{
    if(!m_header_sended) {
        SendHeader();
    }
    va_list args;
    va_start(args, fmt);
    int count = FCGX_VFPrintF(request_->GetFCGX_Request()->out, fmt, args);
    va_end(args);
    return count;
}
Exemplo n.º 5
0
int FCGI_fprintf(FCGI_FILE *fp, const char *format, ...)
{
    va_list ap;
    int n = 0;
    va_start(ap, format);
    if(fp->stdio_stream)
        n = vfprintf(fp->stdio_stream, format, ap);
    else if(fp->fcgx_stream)
        n = FCGX_VFPrintF(fp->fcgx_stream, format, ap);
    va_end(ap);
    return n;
}
Exemplo n.º 6
0
static int io_fcgi_printf(void *context, const char *format, ...)
{
	FCGX_Request *request = (FCGX_Request *)context;
	va_list va;
	int len;
	
	va_start(va, format);
	len = FCGX_VFPrintF(request->out, format, va);
	va_end(va);
	
	return len;
}