Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gevent
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
gevent
Commits
7d27ea1c
Commit
7d27ea1c
authored
Jan 09, 2011
by
Denis Bilenko
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix values of EVHTTP_REQ_GET/POST/.. constants: they were changed in libevent-2.0.9 (issue #62)
parent
6ca9ab94
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
47 additions
and
6 deletions
+47
-6
gevent/evhttp.pxi
gevent/evhttp.pxi
+43
-6
gevent/libevent.h
gevent/libevent.h
+4
-0
No files found.
gevent/evhttp.pxi
View file @
7d27ea1c
__all__
+=
[
'http_request'
,
'http_connection'
,
'http'
]
cdef
extern
from
*
:
cdef
void
emit_ifdef
"#if defined(LIBEVENT_HTTP_MODERN) //"
()
cdef
void
emit_else
"#else //"
()
cdef
void
emit_endif
"#endif //"
()
EVHTTP_REQUEST
=
0
EVHTTP_RESPONSE
=
1
EVHTTP_REQ_GET
=
0
EVHTTP_REQ_POST
=
1
EVHTTP_REQ_HEAD
=
2
EVHTTP_REQ_PUT
=
3
EVHTTP_REQ_DELETE
=
4
HTTP_method2name
=
{
0
:
'GET'
,
1
:
'POST'
,
2
:
'HEAD'
,
3
:
'PUT'
,
4
:
'DELETE'
}
emit_ifdef
()
EVHTTP_REQ_GET
=
1
<<
0
EVHTTP_REQ_POST
=
1
<<
1
EVHTTP_REQ_HEAD
=
1
<<
2
EVHTTP_REQ_PUT
=
1
<<
3
EVHTTP_REQ_DELETE
=
1
<<
4
EVHTTP_REQ_OPTIONS
=
1
<<
5
EVHTTP_REQ_TRACE
=
1
<<
6
EVHTTP_REQ_CONNECT
=
1
<<
7
EVHTTP_REQ_PATCH
=
1
<<
8
HTTP_method2name
=
{
EVHTTP_REQ_GET
:
"GET"
,
EVHTTP_REQ_POST
:
"POST"
,
EVHTTP_REQ_HEAD
:
"HEAD"
,
EVHTTP_REQ_PUT
:
"PUT"
,
EVHTTP_REQ_DELETE
:
"DELETE"
,
EVHTTP_REQ_OPTIONS
:
"OPTIONS"
,
EVHTTP_REQ_TRACE
:
"TRACE"
,
EVHTTP_REQ_CONNECT
:
"CONNECT"
,
EVHTTP_REQ_PATCH
:
"PATCH"
}
emit_else
()
EVHTTP_REQ_GET
=
0
EVHTTP_REQ_POST
=
1
EVHTTP_REQ_HEAD
=
2
HTTP_method2name
=
{
EVHTTP_REQ_GET
:
"GET"
,
EVHTTP_REQ_POST
:
"POST"
,
EVHTTP_REQ_HEAD
:
"HEAD"
,
}
emit_endif
()
cdef
extern
from
*
:
ctypedef
char
*
const_char_ptr
"const char*"
...
...
gevent/libevent.h
View file @
7d27ea1c
...
...
@@ -10,6 +10,10 @@
#if defined(_EVENT_NUMERIC_VERSION) && _EVENT_NUMERIC_VERSION >= 0x2000000
#if _EVENT_NUMERIC_VERSION >= 0x02000900
#define LIBEVENT_HTTP_MODERN
#endif
#include "event2/event.h"
#include "event2/event_struct.h"
#include "event2/event_compat.h"
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment