Ignore:
Timestamp:
Jul 11, 2014, 10:14:03 PM (10 years ago)
Author:
djay
Message:

Inputs passed by reference downloaded in parallel. Conform behavior for DescribeProcess? when the Identifier was not found.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/zoo-project/zoo-kernel/ulinet.h

    r490 r492  
    2727
    2828#include "fcgi_stdio.h"
     29#include "service.h"
    2930#include <stdlib.h>
    3031#include <fcntl.h>
     
    4445#endif
    4546
     47#define MAX_REQ 100
    4648
    4749#ifdef _ULINET
    48 static char CCookie[1024];
     50static char CCookie[MAX_REQ][1024];
    4951#else
    50 extern char HEADER[3072];
    51 extern char CCookie[1024];
     52extern char HEADER[MAX_REQ][3072];
     53extern char CCookie[MAX_REQ][1024];
    5254#endif
    5355
     
    5860  //static pthread_mutex_t hMutexConnect = PTHREAD_MUTEX_INITIALIZER;
    5961
     62static char* waitingRequests[MAX_REQ];
     63
    6064struct MemoryStruct {
    6165  char *memory;
     
    6468
    6569typedef struct {
    66   CURLM *handle;
    67   CURL *ihandle;
     70  CURL *handle;
    6871  struct curl_slist *header;
    6972  char* filename;
    70   char *agent;
    7173  FILE* file;
    7274  size_t size;
     75  unsigned char *pabyData;
     76  unsigned char *mimeType;
    7377  int hasCacheFile;
    7478  int nDataLen;
    7579  int nDataAlloc;
    76   unsigned char *pabyData;
    77   unsigned char *mimeType;
     80  int id;
     81} _HINTERNET;
     82
     83typedef struct {
     84  CURLM *handle;
     85  _HINTERNET ihandle[MAX_REQ];
     86  char *waitingRequests[MAX_REQ];
     87  char *agent;
     88  int nb;
    7889} HINTERNET;
    7990
     
    112123HINTERNET InternetOpen(char* lpszAgent,int dwAccessType,char* lpszProxyName,char* lpszProxyBypass,int dwFlags);
    113124
    114 void InternetCloseHandle(HINTERNET handle);
     125void InternetCloseHandle(HINTERNET* handle);
    115126
    116127#define INTERNET_FLAG_EXISTING_CONNECT         0
     
    137148#  define CHECK_INET_HANDLE(h) (h.handle != 0)
    138149
    139 HINTERNET InternetOpenUrl(HINTERNET hInternet,LPCTSTR lpszUrl,LPCTSTR lpszHeaders,size_t dwHeadersLength,size_t dwFlags,size_t dwContext);
     150HINTERNET InternetOpenUrl(HINTERNET* hInternet,LPCTSTR lpszUrl,LPCTSTR lpszHeaders,size_t dwHeadersLength,size_t dwFlags,size_t dwContext);
     151
     152int processDownloads(HINTERNET* hInternet);
    140153
    141154int freeCookieList(HINTERNET hInternet);
    142155
    143 int InternetReadFile(HINTERNET hInternet,LPVOID lpBuffer,int dwNumberOfBytesToRead,size_t *lpdwNumberOfBytesRead);
    144 
    145 bool InternetGetCookie(LPCTSTR lpszUrl,LPCTSTR lpszCookieName,LPTSTR lpszCookieData,LPDWORD lpdwSize);
     156int InternetReadFile(_HINTERNET hInternet,LPVOID lpBuffer,int dwNumberOfBytesToRead,size_t *lpdwNumberOfBytesRead);
    146157
    147158#ifdef __cplusplus
Note: See TracChangeset for help on using the changeset viewer.

Search

Context Navigation

ZOO Sponsors

http://www.zoo-project.org/trac/chrome/site/img/geolabs-logo.pnghttp://www.zoo-project.org/trac/chrome/site/img/neogeo-logo.png http://www.zoo-project.org/trac/chrome/site/img/apptech-logo.png http://www.zoo-project.org/trac/chrome/site/img/3liz-logo.png http://www.zoo-project.org/trac/chrome/site/img/gateway-logo.png

Become a sponsor !

Knowledge partners

http://www.zoo-project.org/trac/chrome/site/img/ocu-logo.png http://www.zoo-project.org/trac/chrome/site/img/gucas-logo.png http://www.zoo-project.org/trac/chrome/site/img/polimi-logo.png http://www.zoo-project.org/trac/chrome/site/img/fem-logo.png http://www.zoo-project.org/trac/chrome/site/img/supsi-logo.png http://www.zoo-project.org/trac/chrome/site/img/cumtb-logo.png

Become a knowledge partner

Related links

http://zoo-project.org/img/ogclogo.png http://zoo-project.org/img/osgeologo.png