mirror of
https://github.com/lxsang/ant-http
synced 2024-12-25 16:28:21 +01:00
update
This commit is contained in:
parent
f48321e1a1
commit
5d795ce4c3
BIN
dist/antd-1.0.4b.tar.gz
vendored
BIN
dist/antd-1.0.4b.tar.gz
vendored
Binary file not shown.
@ -483,10 +483,10 @@ void *serve_file(void *data)
|
||||
char *path = (char *)dvalue(rq->request, "ABS_RESOURCE_PATH");
|
||||
char *mime_type = (char *)dvalue(rq->request, "RESOURCE_MIME");
|
||||
ctype(rq->client, mime_type);
|
||||
if (is_bin(path))
|
||||
/*if (is_bin(path))
|
||||
__fb(rq->client, path);
|
||||
else
|
||||
__f(rq->client, path);
|
||||
else*/
|
||||
__f(rq->client, path);
|
||||
return task;
|
||||
}
|
||||
|
||||
|
@ -477,7 +477,7 @@ int __b(void* client, const unsigned char* data, int size)
|
||||
}
|
||||
return 1;
|
||||
}
|
||||
int __fb(void* client, const char* file)
|
||||
int __f(void* client, const char* file)
|
||||
{
|
||||
printf("Open file %s\n",file );
|
||||
unsigned char buffer[BUFFLEN];
|
||||
@ -497,6 +497,7 @@ int __fb(void* client, const char* file)
|
||||
fclose(ptr);
|
||||
return 1;
|
||||
}
|
||||
/*
|
||||
int __f(void* client, const char* file)
|
||||
{
|
||||
char buf[BUFFLEN];
|
||||
@ -520,7 +521,7 @@ int __f(void* client, const char* file)
|
||||
fclose(ptr);
|
||||
return 1;
|
||||
}
|
||||
|
||||
*/
|
||||
int upload(const char* tmp, const char* path)
|
||||
{
|
||||
return !rename(tmp, path);
|
||||
|
@ -95,7 +95,7 @@ int __ti(void*,int);
|
||||
int __t(void*, const char*,...);
|
||||
int __b(void*, const unsigned char*, int);
|
||||
int __f(void*, const char*);
|
||||
int __fb(void*, const char*);
|
||||
//int __fb(void*, const char*);
|
||||
int upload(const char*, const char*);
|
||||
|
||||
void set_cookie(void*, const char*,dictionary,const char*);
|
||||
|
Loading…
Reference in New Issue
Block a user