The SWORD Project  1.9.0.svnversion
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
curlhttpt.cpp File Reference
#include <vector>
#include <cctype>
#include <curl/curl.h>
#include <curl/easy.h>
#include <swlog.h>
#include <filemgr.h>
#include <curlhttpt.h>
+ Include dependency graph for curlhttpt.cpp:

Go to the source code of this file.

Classes

struct  SWORD_NAMESPACE_START::FtpFile
 

Namespaces

 SWORD_NAMESPACE_START
 

Functions

const char * findSizeStart (const char *buffer)
 
static int SWORD_NAMESPACE_START::my_httpfprogress (void *clientp, double dltotal, double dlnow, double ultotal, double ulnow)
 
static int SWORD_NAMESPACE_START::my_httpfwrite (void *buffer, size_t size, size_t nmemb, void *stream)
 
static int SWORD_NAMESPACE_START::myhttp_trace (CURL *handle, curl_infotype type, unsigned char *data, size_t size, void *userp)
 

Function Documentation

const char* findSizeStart ( const char *  buffer)

Definition at line 194 of file curlhttpt.cpp.

194  {
195  const char *listing = buffer;
196  const char *pEnd;
197 
198  pEnd = strstr(listing, "<td");
199  if(pEnd == NULL) {
200  return NULL;
201  }
202  listing = pEnd+2;
203  pEnd = strstr(listing, "<td");
204  if(pEnd == NULL)
205  return NULL;
206  listing = pEnd+2;
207  pEnd = strchr(listing, '>');
208  if(pEnd == NULL)
209  return NULL;
210 
211  return pEnd+1;
212 }
preg buffer
Definition: regex.c:8089
return NULL
Definition: regex.c:7953