Aureus
c726723545
Use explicit pointer casting for c++ compatibility ( #826 )
2020-06-01 15:21:27 -07:00
Michael Grunder
8e0264cfd6
Allow users to replace allocator and handle OOM everywhere. ( #800 )
...
* Adds an indirection to every allocation/deallocation to allow users to
plug in ones of their choosing (use custom functions, jemalloc, etc).
* Gracefully handle OOM everywhere in hiredis. This should make it possible
for users of the library to have more flexibility in how they handle such situations.
* Changes `redisReaderTask->elements` from an `int` to a `long long` to prevent
a possible overflow when transferring the task elements into a `redisReply`.
* Adds a configurable `max elements` member to `redisReader` that defaults to
2^32 - 1. This can be set to "unlimited" by setting the value to zero.
2020-05-22 09:27:49 -07:00
Michael Grunder
994d2fd77d
Support timeouts in libev adapater ( #795 )
...
Add support for timeouts in our libev adapter.
See #795
2020-05-04 10:35:30 -07:00
Michael Grunder
a5613f3f7f
Use correct libuv call on Windows ( #784 )
...
Explicitly call `uv_poll_init_socket` as that has slightly different semantics on Windows (and is identical to `uv_poll_init` on Linux).
http://docs.libuv.org/en/v1.x/poll.html#c.uv_poll_init_socket
2020-04-09 12:39:49 -07:00
Michael Grunder
669ac9d0c8
Safe allocation wrappers ( #754 )
...
Create allocation wrappers with a configurable OOM handler (defaults to abort()).
See #752 , #747
2020-01-28 12:13:05 -08:00
valentino
d9e0299f1c
fix redisLibeventEvents init
2019-02-20 09:11:10 -05:00
Mark Nunberg
f0a7595056
libevent: call destroy from cleanup
...
also, indentation fix
2019-02-20 09:11:10 -05:00
Mark Nunberg
f60c5506fe
Add EV_PERSIST flag to read events
...
This will avoid the need to constantly reschedule the event
2019-02-20 09:11:10 -05:00
Mark Nunberg
24e6166fed
libevent: fix invalid mem access on delete within callback enter
2019-02-20 09:11:10 -05:00
valentino
847a20122f
Fix memory leaks
2019-02-20 09:10:10 -05:00
Mark Nunberg
35a0a1f369
read/write timeouts
2019-02-20 09:10:10 -05:00
Yossi Gottlieb
9ce15c4b39
Fix errors not propagating properly with libuv.h.
2018-11-04 10:04:53 +02:00
zfz
515228e5a1
Update libevent.h
...
event_del can not free the "e->rev" and "e->wev",that will leak when reconnect the redis
2017-03-28 16:46:55 +08:00
not-a-robot
33152ad163
Auto merge of #429 - xinchuantao:master, r=badboy
...
using new version libevent
2016-12-09 11:37:25 +01:00
Paul Scott
cbb956567b
Prevented uv adapter from calling write when context has been freed
2016-09-19 11:48:54 +10:00
Chris.Xin
386802e809
using new version libevent
2016-05-20 18:55:57 +08:00
Dmitry Bakhvalov
c18a564818
Added MacOS X addapter and corresponding example.
...
Added MacOS X support via CoreFoundation run loop.
2015-07-27 23:19:14 +02:00
Pietro Cerutti
4a632a6038
Make sure to disconnect the adapter in the destructor
2015-07-27 23:17:41 +02:00
Pietro Cerutti
9069b147b0
Fix typo
2015-07-27 23:17:41 +02:00
Pietro Cerutti
1984b309b8
Add hooks for read/write/cleanup
2015-07-27 23:17:41 +02:00
Pietro Cerutti
8ef7d595ac
Add Qt adapter and relative example.
2015-07-27 23:17:41 +02:00
Gergely Nagy
3b153cbf9d
Add an Ivykis adapter
...
This adds a new adapter and an example for using hiredis with the ivykis
async I/O library.
Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
2015-07-27 22:48:05 +02:00
Simon Ninon
1c884ec75b
Use explicit casts for void* pointer in order to compile in C++
2015-06-22 14:44:57 +02:00
Christian Hergert
0c9ff5bb03
Add GLib 2.0 adapter
...
[Cleaned up Makefile and header includes. Didn't change crazy
coding style because it's the convention for GLib systems.]
Closes #83
Closes #71
2015-01-05 16:39:30 -05:00
torque
9c57314489
Cleanup libuv adapter
...
This:
- Removes misplaced libuv function prototype
- Includes stdlib for free()
Closes #251
2015-01-05 16:38:57 -05:00
antirez
2d66c4814e
Add missing license and copyright for adapters
...
This is a backport of
d01aad329c
2014-04-09 17:02:42 -04:00
Charlie Somerville
4ede1bada1
Define redisLibuvAttach as static
...
Closes #206
2014-04-09 17:02:42 -04:00
John Graham
f20f5ad102
Libuv: Fix compile warnings and C++ compatability
...
Closes #189
2014-04-09 17:02:42 -04:00
Erik Dubbelboer
0396159214
Removed unnecessary comments
2013-06-09 14:43:03 +02:00
Erik Dubbelboer
61277d0925
Added libuv adapter
2013-06-04 15:06:43 +02:00
R. Tyler Croy
0bf4dded31
Convert the rest of the async adapters contain static functions for easier linking
2011-06-27 12:40:59 -07:00
R. Tyler Croy
62c8917f2f
Make libev adapter functions static to fix linking
...
This will allow two different compilation units to include libev.h
and link together
2011-06-27 12:17:37 -07:00
R. Tyler Croy
0f2e899c41
Add implied include of stdlib.h
2011-06-27 12:17:37 -07:00
Pieter Noordhuis
eb63a565e9
sys/types.h is included by libevent itself
2011-04-21 18:11:45 +02:00
Pieter Noordhuis
18c55a8f1e
Scope event library related data and hooks to a struct
2010-12-29 15:41:03 +01:00
Pieter Noordhuis
af7369a253
Use extra field for adapter-specific data
...
This makes sure that the "data" field on the asynchronous context can be
used for user-specific data.
2010-12-01 16:43:24 +01:00
Pieter Noordhuis
9af1574d6e
Add adapter for the Redis-bundled ae event library
2010-12-01 13:47:58 +01:00
Pieter Noordhuis
fb49cd1988
Make the libev adapter work without support for multiple event loops
2010-11-23 15:55:32 +01:00
Pieter Noordhuis
4f4d1ed7b5
Explicit casts for the libev adapter
2010-11-22 09:45:55 +01:00
Ryan Tecco
0d925bb497
add explicit casts for C++ compiles - C++ disallows implicit casts from
...
void*
2010-11-21 16:26:55 -08:00
Pieter Noordhuis
89e0622535
Move libev/libevent headers to adapters directory
2010-11-01 10:42:32 +01:00