|
c2aa7dcb
|
2015-05-05T10:37:00
|
|
Call underlying bev ctrl SET_FD on filtered bufferevents
If a bufferevent_filter is set on an underlying bufferevent which has
ctrl functions, bufferevent_filter needs to handle this.
For now I have added just BEV_CTRL_SET_FD, since this is needed for
bufferevent_sock to assign file descriptors to the proper
bufferevent_read/write callbacks.
A good example of the problem can be found in issue #237
https://github.com/libevent/libevent/issues/237
|
|
a695a720
|
2015-04-27T22:43:04
|
|
Fix potential fd leak in listener_read_cb()
As pointed out by harlan_ in #libevent after running a coverity sweep.
If the listener is free'd, 'new_fd' is never closed.
|
|
6e7a580c
|
2015-03-24T17:45:52
|
|
tab
|
|
38cef641
|
2015-03-24T17:29:40
|
|
fix the return value of event_deferred_cb_schedule_
|
|
31c6d45f
|
2015-02-17T12:37:30
|
|
Merge pull request #220 from miniupnp/fix_warnings
Fix warnings
|
|
0c7f2178
|
2015-02-16T23:42:54
|
|
Fix mixed declarations and code (forbidden by ISO C90)
|
|
746d2c50
|
2015-02-16T23:41:53
|
|
Fix "function declaration isn’t a prototype"
add "void" to argument list
|
|
d59113a4
|
2015-02-05T15:24:55
|
|
Merge pull request #214 from JoakimSoderberg/appveyor
Forgot to install OpenSSL for appveyor
|
|
26164a56
|
2015-02-05T20:21:04
|
|
Forgot to install OpenSSL for appveyor
|
|
874ea871
|
2015-02-05T13:37:24
|
|
Merge pull request #117 from JoakimSoderberg/appveyor
Add support for appveyor.com windows CI
|
|
5f89c37e
|
2015-02-05T19:24:19
|
|
Add support for appveyor.com windows CI
This does the same thing as Travis-CI but for windows.
@nmathewson
Go to: https://ci.appveyor.com/login -> Login using Github
Click **+New Project** -> Choose **Github** to the left -> Find **Libevent** in the list and click **Add**
|
|
deca354c
|
2015-02-05T12:14:16
|
|
Merge pull request #116 from JoakimSoderberg/fix_build_tree_cmake_config
This fixes a bug introduced in 27bd9faf498b91923296cc91643e03ec4055c230
|
|
19ba4543
|
2015-02-05T00:56:58
|
|
This fixes a bug introduced in 27bd9faf498b91923296cc91643e03ec4055c230
CMake configuration files are intended to be used by other projects to find the library. Specifically the CMake find_package command can use it to find all files related to the project.
The idea is to support 2 different CMake configuration files for Libevent. One if you simply build libevent that is generated for the build tree.
And a second one that is generated for an install target that will be installed on the system and point to where on the system the lib files and such can be find.
So for instance, in the build tree the config would set the cmake variable `LIBEVENT_INCLUDE_DIRS` to `/path/to/libevent/build/include`.
And for the system config it would be set to `/usr/local/include` (or whatever target the user chose when running cmake).
27bd9faf498b91923296cc91643e03ec4055c230 changed this behavior so that both configs would point to the system wide path `/usr/local/include`
This meant that projects just wanting to import directly for the build tree would fail.
|
|
a77a82a0
|
2015-02-04T08:37:32
|
|
Merge remote-tracking branch 'azat/be-pair-fix-freeing-shared-lock-v5'
|
|
51821e20
|
2015-02-04T08:33:42
|
|
Merge pull request #207 from azat/avoid-leaking-of-event_debug_map_HT_GROW
Avoid leaking of event_debug_map_HT_GROW
|
|
4472ec68
|
2015-02-03T15:57:31
|
|
Merge pull request #212 from xbao/master
changed strtotimeval signature to avoid conflict with Android NDK sys/time.h header (#211)
|
|
1cae3ae1
|
2015-02-02T13:57:50
|
|
Merge remote-tracking branch 'public/master'
|
|
537177d3
|
2015-02-02T13:57:22
|
|
New function to get address for nameserver.
|
|
bdbc823f
|
2015-01-28T17:17:02
|
|
changed strtotimeval signature as per #211
|
|
62eaa889
|
2015-01-27T10:07:22
|
|
Merge pull request #210 from mc-server/master
Added cmake-generated files to ignore list.
|
|
6c12bfec
|
2015-01-27T15:30:52
|
|
Added cmake-generated files to ignore list.
These are generated by cmake on Windows with MSVC.
|
|
a558fcdb
|
2015-01-26T00:31:23
|
|
be_pair/regress: cover use of shared lock (lock/unlock/free)
For more info look at 92a359ee3adf4636db508e6c6d7179d4d59eaafc
("be_pair: release shared lock with the latest of bufferevent_pair")
|
|
e5c87d18
|
2015-01-26T00:29:15
|
|
event_free_debug_globals_locks(): disable lock debugging
This will allow to use library event after
event_free_debug_globals_locks()/libevent_global_shutdown() without
invalid read/write's.
|
|
ccc55937
|
2015-01-26T00:28:46
|
|
evthread: evthreadimpl_disable_lock_debugging_() for libevent_global_shutdown()
|
|
c0b34f6f
|
2015-01-26T00:27:41
|
|
evthread: add evthread_get_{lock,condition}_callbacks() helpers
|
|
92a359ee
|
2015-01-03T19:37:15
|
|
be_pair: release shared lock with the latest of bufferevent_pair
Then next code sample will use free'd lock:
evthread_use_pthreads();
...
assert(!bufferevent_pair_new(base, BEV_OPT_THREADSAFE, pair));
...
bufferevent_free(pair[0]); # refcnt == 0 -> unlink
bufferevent_free(pair[1]); # refcnt == 0 -> unlink
...
event_base_free() -> finalizers -> EVTHREAD_FREE_LOCK(bev1->lock)
-> BEV_LOCK(bev2->lock) <-- *already freed*
While if you will reverse the order:
bufferevent_free(pair[1]); # refcnt == 0 -> unlink
bufferevent_free(pair[0]); # refcnt == 0 -> unlink
...
event_base_free() -> finalizers -> BEV_LOCK(bev2->lock)/!own_lock/BEV_UNLOCK(bev2->lock)
-> EVTHREAD_FREE_LOCK(bev1->lock) (own_lock)
It is ok now, but I guess that it will be better to relax order of
freeing pairs.
|
|
4d66552a
|
2015-01-22T12:15:01
|
|
Merge pull request #115 from jer-gentoo/master
EVBUFFER_PTR_SET -> EVBUFFER_PTR_ADD
|
|
8674e4fb
|
2015-01-21T11:24:23
|
|
EVBUFFER_PTR_SET -> EVBUFFER_PTR_ADD
Looks like EVBUFFER_PTR_ADD should have been used instead of EVBUFFER_PTR_SET.
|
|
3540a193
|
2015-01-08T04:45:49
|
|
regress_dns: drop hack for event_debug_map_HT_GROW in leak tests
|
|
941faaed
|
2015-01-08T04:45:27
|
|
event: call event_disable_debug_mode() in libevent_global_shutdown()
This will avoid leaking of event_debug_map_HT_GROW
I buildin it into libevent_glboal_shutdown() because
event_disable_debug_mode() -> event_free_debug_globals() ->
event_free_debug_globals_locks() will clean event_debug_map_lock_ that
used in event_disable_debug_mode().
|
|
597c7b25
|
2015-01-08T04:43:37
|
|
ht-internal: don't reset hth_table_length explicitly in name_##HT_CLEAR
name_##HT_CLEAR calls name_##HT_INIT that reset hth_table_length to 0.
|
|
0b49ae34
|
2015-01-05T09:33:48
|
|
Update changelog
|
|
2c827e76
|
2015-01-05T09:33:02
|
|
Merge branch '21_cve_2014_6272_v2'
|
|
841ecbd9
|
2015-01-05T09:32:53
|
|
Fix CVE-2014-6272 in Libevent 2.1
For this fix, we need to make sure that passing too-large inputs to
the evbuffer functions can't make us do bad things with the heap.
Also, lower the maximum chunk size to the lower of off_t, size_t maximum.
This is necessary since otherwise we could get into an infinite loop
if we make a chunk that 'misalign' cannot index into.
|
|
683f5568
|
2015-01-05T09:16:12
|
|
Increment version to 2.1.5-beta
|
|
0eb39194
|
2015-01-05T08:50:30
|
|
work on changelog for 2.1.5-alpah
|
|
8a29f3b3
|
2015-01-04T10:27:02
|
|
Merge pull request #201 from nsuke/cmake-shared-build
Fix CMake shared library build
|
|
e69d9109
|
2015-01-03T02:22:31
|
|
Fix CMake shared library build
This fixes following problems in shared library build:
* visibility=hidden was not enabled for gcc because of incorrect variable name
* test programs that need internal APIs caused link errors
|
|
f05a0d53
|
2014-12-23T09:35:40
|
|
Merge pull request #197 from JohnOhl/fix-clang-compile-warnings
Fix warnings when compiling with clang 3.5
|
|
f5b47657
|
2014-12-22T00:46:56
|
|
Fix warnings when compiling with clang 3.5
|
|
cb737041
|
2014-12-15T12:50:11
|
|
Fix annoying heisenbug in test-time.c
|
|
37df827a
|
2014-12-08T10:26:01
|
|
Merge pull request #192 from miniupnp/master
Fix mixed declarations and code (forbidden by ISO C90)
|
|
8afbdbc4
|
2014-12-08T10:21:00
|
|
Fix mixed declarations and code (forbidden by ISO C90)
|
|
f2645f80
|
2014-11-19T12:18:05
|
|
Implement new/free for struct evutil_monotonic_timer and export monotonic time functions
|
|
6ae44b5d
|
2014-12-01T08:32:23
|
|
Merge remote-tracking branch 'origin/patches-2.0'
|
|
fb7e76ae
|
2014-11-30T11:05:40
|
|
Fix evbuffer_peek() with len==-1 and start_at non-NULL.
|
|
37145c56
|
2014-11-30T21:07:55
|
|
Merge remote-tracking branch 'public/patches-2.0'
Conflicts:
ChangeLog
event.c
|
|
1da2f42b
|
2014-11-30T21:02:25
|
|
Merge branch 'patches-2.0' of github.com:libevent/libevent into patches-2.0
|
|
d9469d39
|
2014-11-30T21:02:06
|
|
Start on 2.1.5-alpha/beta changelog
|
|
5ae52872
|
2014-11-30T19:38:23
|
|
Work on the changelog for 2.0.22
|
|
7fd49414
|
2014-11-30T19:26:20
|
|
Merge remote-tracking branch 'origin/pr/182'
|
|
23133cac
|
2014-11-30T19:25:21
|
|
Merge remote-tracking branch 'origin/pr/180'
|
|
3c7d6fca
|
2014-09-22T12:19:37
|
|
Fix race caused by event_active
There is a race between manual event_active and natural event activation. If both happen at the same time on the same FD, they would both be protected by the same event base lock except for 1 LoC where the fields of struct event are read without any kind of lock. This commit does those reads into local variables inside the lock and then invokes the callback with those local arguments outside the lock. In 2.0-stable, none of this is inside the lock; in HEAD, only the callback is read inside the lock. This gets the callback and all 3 arguments inside the lock before calling it outside the lock.
|
|
c51c85d3
|
2014-11-30T11:11:33
|
|
Merge remote-tracking branch 'origin/pr/175'
|
|
a5d43cf4
|
2014-11-30T11:09:50
|
|
Merge branch 'evbufer_peek_fix_v3'
|
|
154006ad
|
2014-11-30T11:09:28
|
|
More evbuffer_peek() test cases
|
|
e2d139dd
|
2014-11-11T14:25:47
|
|
test/evbuffer_peek: add regress in case we have first buffer greater
|
|
ba59923a
|
2014-11-30T11:05:40
|
|
Fix evbuffer_peek() with len==-1 and start_at non-NULL.
|
|
4f360f89
|
2014-11-30T10:23:39
|
|
Merge remote-tracking branch 'origin/pr/186'
|
|
befbd130
|
2014-09-20T15:25:53
|
|
Fix cmake error when the Module path has more than one entry.
CMAKE_MODULE_PATH is usually a list instead of single entry. Especially
for projects contain sub cmake projects. My patch replace the
CMAKE_MODULE_PATH with fixed path, to locate the `.in` file.
|
|
5ebad45e
|
2014-11-24T01:09:13
|
|
Merge pull request #189 from azat/be_async-avoid-doule-close
be async: avoid double close()
|
|
f133b869
|
2014-11-21T09:00:12
|
|
be async: avoid double close()
In case when between this two close (close(F), close(F)) some open()
will be executed, than we will close newly opened fd.
Reported-by: xujiezhige@163.com
|
|
10fe4ef3
|
2014-11-16T23:40:16
|
|
Prevent duplicate event_del on fd
|
|
61262a0f
|
2014-11-12T20:16:18
|
|
evdns: avoid read-after-free in evdns_request_timeout_callback()
In evdns_request_timeout_callback() in case we a giving up, we call
request_finished() which will free() req structure, however we ns from
it to fail it, so save pointer to ns to call nameserver_failed() on
them.
Founded with valgrind:
$ valgrind regress dns/retry
==10497== Memcheck, a memory error detector
==10497== Copyright (C) 2002-2013, and GNU GPL'd, by Julian Seward et al.
==10497== Using Valgrind-3.10.0 and LibVEX; rerun with -h for copyright info
==10497== Command: regress dns/retry
==10497==
dns/retry: [forking] ==10498== Invalid read of size 8
==10498== at 0x4C309D: evdns_request_timeout_callback (evdns.c:2179)
==10498== by 0x49EA95: event_process_active_single_queue (event.c:1576)
==10498== by 0x49EFDD: event_process_active (event.c:1668)
==10498== by 0x49F6DD: event_base_loop (event.c:1891)
==10498== by 0x49F063: event_base_dispatch (event.c:1702)
==10498== by 0x44C7F1: dns_retry_test_impl (regress_dns.c:724)
==10498== by 0x44CF60: dns_retry_test (regress_dns.c:749)
==10498== by 0x48A8A1: testcase_run_bare_ (tinytest.c:105)
==10498== by 0x48A94E: testcase_run_forked_ (tinytest.c:189)
==10498== by 0x48AB73: testcase_run_one (tinytest.c:247)
==10498== by 0x48B4C2: tinytest_main (tinytest.c:434)
==10498== by 0x477FC7: main (regress_main.c:459)
==10498== Address 0x6176ef8 is 40 bytes inside a block of size 342 free'd
==10498== at 0x4C29E90: free (vg_replace_malloc.c:473)
==10498== by 0x4A4411: event_mm_free_ (event.c:3443)
==10498== by 0x4BE8C5: request_finished (evdns.c:702)
==10498== by 0x4C3098: evdns_request_timeout_callback (evdns.c:2178)
==10498== by 0x49EA95: event_process_active_single_queue (event.c:1576)
==10498== by 0x49EFDD: event_process_active (event.c:1668)
==10498== by 0x49F6DD: event_base_loop (event.c:1891)
==10498== by 0x49F063: event_base_dispatch (event.c:1702)
==10498== by 0x44C7F1: dns_retry_test_impl (regress_dns.c:724)
==10498== by 0x44CF60: dns_retry_test (regress_dns.c:749)
==10498== by 0x48A8A1: testcase_run_bare_ (tinytest.c:105)
==10498== by 0x48A94E: testcase_run_forked_ (tinytest.c:189)
==10498==
==10498==
==10498== HEAP SUMMARY:
==10498== in use at exit: 0 bytes in 0 blocks
==10498== total heap usage: 83 allocs, 83 frees, 10,020 bytes allocated
==10498==
==10498== All heap blocks were freed -- no leaks are possible
==10498==
==10498== For counts of detected and suppressed errors, rerun with: -v
==10498== ERROR SUMMARY: 1 errors from 1 contexts (suppressed: 0 from 0)
OK
1 tests ok. (0 skipped)
==10497==
==10497== HEAP SUMMARY:
==10497== in use at exit: 0 bytes in 0 blocks
==10497== total heap usage: 3 allocs, 3 frees, 96 bytes allocated
==10497==
==10497== All heap blocks were freed -- no leaks are possible
==10497==
==10497== For counts of detected and suppressed errors, rerun with: -v
==10497== ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 0 from 0)
Bug was introduced in 97c750d6602517f22a1100f16592b421c38f2a45 ("evdns:
fail ns after we are failing/retrasmitting request").
|
|
b0e99244
|
2014-10-29T03:40:44
|
|
Add test for evhttp_connection_free_on_completion
|
|
2b9ec4c1
|
2014-10-26T01:18:10
|
|
Implement interface that provides the ability to have an outbound evhttp_connection free itself once all requests have completed
|
|
b361b8a6
|
2014-10-16T22:56:49
|
|
remove trailing comma from enum
makes being included from something with -std=c89 happy
|
|
6dba1694
|
2014-10-13T17:59:32
|
|
Merge pull request #179 from pysiak/master
Provide support for SO_REUSEPORT through LEV_OPT_REUSABLE_PORT
|
|
b625361a
|
2014-10-13T17:28:14
|
|
Provide support for SO_REUSEPORT through LEV_OPT_REUSABLE_PORT
|
|
c750c704
|
2014-10-09T11:48:38
|
|
Merge pull request #174 from azat/dns-fail-disable-when-inactive-fix-v3
Dns fail disable when inactive fix v3
|
|
e69f3908
|
2014-10-09T11:30:01
|
|
Merge pull request #171 from azat/bufferevent-openssl-fixes-v4
bufferevent_openssl: reset fd_is_set when setfd with -1 is called
|
|
2e2d18bc
|
2014-10-09T11:29:17
|
|
Merge pull request #170 from azat/https-client-retries
https-client: add -retries argument, for connection retries
|
|
163df09b
|
2014-10-09T10:42:20
|
|
Merge pull request #108 from JoakimSoderberg/minor_issues
Fix compilation for older OpenSSL versions.
|
|
0fb71c35
|
2014-10-09T10:14:30
|
|
Merge remote-tracking branch 'origin/patches-2.0'
|
|
be1aeff2
|
2014-10-09T10:14:12
|
|
Fix a typo in a doxygen comment. Reported by 亦得.
|
|
bc79cc5c
|
2014-09-27T21:29:45
|
|
http: reset connection before installing retry timer (fix http retries handling)
This will fix some invalid read/write:
==556== Invalid read of size 8
==556== at 0x4E4EEC6: event_queue_remove_timeout (minheap-internal.h:178)
==556== by 0x4E508AA: event_del_nolock_ (event.c:2764)
==556== by 0x4E53535: event_base_loop (event.c:3088)
==556== by 0x406FCFA: dispatch (libcrawl.c:271)
==556== by 0x402863: main (crawler.c:49)
==556== Address 0x68a3f18 is 152 bytes inside a block of size 400 free'd
==556== at 0x4C29C97: free (in /usr/local/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
==556== by 0x406F140: renew (libcrawl.c:625)
==556== by 0x4E6CDE9: evhttp_connection_cb_cleanup (http.c:1331)
==556== by 0x4E6E2B2: evhttp_connection_cb (http.c:1424)
==556== by 0x4E4DF2D: bufferevent_writecb (bufferevent_sock.c:310)
==556== by 0x4E52D1D: event_process_active_single_queue (event.c:1584)
==556== by 0x4E53676: event_base_loop (event.c:1676)
==556== by 0x406FCFA: dispatch (libcrawl.c:271)
==556== by 0x402863: main (crawler.c:49)
But this one because of some invalid write before (I guess).
It is 100% reproduced during massive crawling (because this process
has many different servers), but after spending some time for trying to
reproduce this using some simple tests/utils I gave up for a few days (I
have a lot of work to do), but I'm sending this patch as a reminder.
Just in case, I've tried next tests:
- mixing timeouts/retries
- shutdown http server and return it back
- slow dns server for first request
- sleep before accept
- hacking libevent sources to change the behaviour of http layer (so it
will go into that function which I'm insterested in).
|
|
97c750d6
|
2014-09-30T01:34:04
|
|
evdns: fail ns after we are failing/retrasmitting request
In case we are failing request (evdns_request_timeout_callback()), we
delete timeout_event in request_finished(), while just before calling
request_finished() (for failing request) there was a call to
nameserver_failed(), that add event for timeout_event, IOW we must fail
ns after request because otherwise we will not have timeout_event
actived, and we will waiting forever.
Before this patch the dns/retry_disable_when_inactive will wait forever,
after - OK.
|
|
3ca9d43d
|
2014-04-10T19:33:45
|
|
evdns: add retry/reissue tests for EVDNS_BASE_DISABLE_WHEN_INACTIVE
|
|
74d0eee8
|
2014-04-10T19:30:47
|
|
evdns: fix EVDNS_BASE_DISABLE_WHEN_INACTIVE in case retransmit/retry
|
|
5c7282f7
|
2014-09-24T13:46:09
|
|
Fix compilation for older OpenSSL versions.
For instance OpenSSL 0.9.7 does not have SSL_set_tlsext_host_name.
Also add the missing EVENT__DISABLE_SAMPLES CMake option.
|
|
3da84c29
|
2014-09-21T18:29:17
|
|
bufferevent_openssl: reset fd_is_set when setfd with -1 is called
Otherwise we will use old fd after close(2) called on it:
(Traces trimmed, to minimize it)
$ strace -keclose,open,socket,epoll_ctl https-client -url https://libevent.org
socket(PF_INET, SOCK_STREAM|SOCK_NONBLOCK, IPPROTO_IP) = 5
> /lib/x86_64-linux-gnu/libc-2.19.so(socket+0x7) [0xe6da7]
> /usr/lib/libevent-2.1.so.4.0.0(evutil_socket_+0x25) [0x27835]
> /usr/lib/libevent-2.1.so.4.0.0(bufferevent_socket_connect+0xe9) [0x1b1a9]
> /usr/lib/libevent-2.1.so.4.0.0(bufferevent_socket_connect+0x21f) [0x1b2df]
> /usr/lib/libevent-2.1.so.4.0.0(evutil_getaddrinfo_async_+0x65) [0x271a5]
> /usr/lib/libevent-2.1.so.4.0.0(bufferevent_socket_connect_hostname+0x106) [0x1b416]
> /usr/lib/libevent-2.1.so.4.0.0(evhttp_connection_connect_+0xe7) [0x39f07]
> /usr/lib/libevent-2.1.so.4.0.0(evhttp_make_request+0xb8) [0x3a218]
epoll_ctl(3, EPOLL_CTL_ADD, 5, {EPOLLIN, {u32=5, u64=5}}) = 0
> ...
> /usr/lib/libevent_openssl-2.1.so.4.0.0(_init+0xfdd) [0x2ced]
> /usr/lib/libevent-2.1.so.4.0.0(bufferevent_setfd+0x3b) [0x16d9b]
> /usr/lib/libevent-2.1.so.4.0.0(bufferevent_socket_connect+0x75) [0x1b135]
> /usr/lib/libevent-2.1.so.4.0.0(bufferevent_socket_connect+0x21f) [0x1b2df]
> /usr/lib/libevent-2.1.so.4.0.0(evutil_getaddrinfo_async_+0x65) [0x271a5]
> /usr/lib/libevent-2.1.so.4.0.0(bufferevent_socket_connect_hostname+0x106) [0x1b416]
> /usr/lib/libevent-2.1.so.4.0.0(evhttp_connection_connect_+0xe7) [0x39f07]
> /usr/lib/libevent-2.1.so.4.0.0(evhttp_make_request+0xb8) [0x3a218]
epoll_ctl(3, EPOLL_CTL_MOD, 5, {EPOLLIN|EPOLLOUT, {u32=5, u64=5}}) = 0
> ...
> /usr/lib/libevent_openssl-2.1.so.4.0.0(_init+0xfee) [0x2cfe]
> /usr/lib/libevent-2.1.so.4.0.0(bufferevent_setfd+0x3b) [0x16d9b]
> /usr/lib/libevent-2.1.so.4.0.0(bufferevent_socket_connect+0x75) [0x1b135]
> /usr/lib/libevent-2.1.so.4.0.0(bufferevent_socket_connect+0x21f) [0x1b2df]
> /usr/lib/libevent-2.1.so.4.0.0(evutil_getaddrinfo_async_+0x65) [0x271a5]
> /usr/lib/libevent-2.1.so.4.0.0(bufferevent_socket_connect_hostname+0x106) [0x1b416]
> /usr/lib/libevent-2.1.so.4.0.0(evhttp_connection_connect_+0xe7) [0x39f07]
> /usr/lib/libevent-2.1.so.4.0.0(evhttp_make_request+0xb8) [0x3a218]
epoll_ctl(3, EPOLL_CTL_MOD, 5, {EPOLLOUT, {u32=5, u64=5}}) = 0
> ...
> /usr/lib/libevent_openssl-2.1.so.4.0.0(_init+0xbbc) [0x28cc]
> /usr/lib/libevent_openssl-2.1.so.4.0.0(_init+0xd96) [0x2aa6]
> /usr/lib/libevent_openssl-2.1.so.4.0.0(_init+0xeb8) [0x2bc8]
> /usr/lib/libevent-2.1.so.4.0.0(event_free+0x3fe) [0x1fd1e]
> /usr/lib/libevent-2.1.so.4.0.0(event_base_loop+0x407) [0x20677]
epoll_ctl(3, EPOLL_CTL_DEL, 5, 7fffa1f841e0) = 0
> ...
> /usr/lib/libevent_openssl-2.1.so.4.0.0(_init+0xbc4) [0x28d4]
> /usr/lib/libevent_openssl-2.1.so.4.0.0(_init+0xd96) [0x2aa6]
> /usr/lib/libevent_openssl-2.1.so.4.0.0(_init+0xeb8) [0x2bc8]
> /usr/lib/libevent-2.1.so.4.0.0(event_free+0x3fe) [0x1fd1e]
> /usr/lib/libevent-2.1.so.4.0.0(event_base_loop+0x407) [0x20677]
close(5) = 0
> /lib/x86_64-linux-gnu/libpthread-2.19.so(__close_nocancel+0x7) [0xeb20]
> /usr/lib/libevent-2.1.so.4.0.0(evhttp_connection_reset_+0x55) [0x373f5]
> /usr/lib/libevent-2.1.so.4.0.0(evhttp_connection_connect_+0x1d) [0x39e3d]
> /usr/lib/libevent-2.1.so.4.0.0(event_free+0x3fe) [0x1fd1e]
> /usr/lib/libevent-2.1.so.4.0.0(event_base_loop+0x407) [0x20677]
epoll_ctl(3, EPOLL_CTL_ADD, 5, {EPOLLIN, {u32=5, u64=5}}) = -1 EBADF (Bad file descriptor)
) = -1 EBADF (Bad file descriptor)
/src/oss/strace-code/strace: Can't initiate libunwind: No such process
> ...
> /usr/lib/libevent_openssl-2.1.so.4.0.0(_init+0xfdd) [0x2ced]
> /usr/lib/libevent-2.1.so.4.0.0(bufferevent_setfd+0x3b) [0x16d9b]
> /usr/lib/libevent-2.1.so.4.0.0(evhttp_connection_connect_+0x14c) [0x39f6c]
> /usr/lib/libevent-2.1.so.4.0.0(event_free+0x3fe) [0x1fd1e]
> /usr/lib/libevent-2.1.so.4.0.0(event_base_loop+0x407) [0x20677]
/src/oss/strace-code/strace: Exit of unknown pid 28185 seen
[warn] Epoll ADD(1) on fd 5 failed. Old events were 0; read change was 1 (add); write change was 0 (none); close change was 0 (none): Bad file descriptor
epoll_ctl(3, EPOLL_CTL_ADD, 5, {EPOLLOUT, {u32=5, u64=5}}) = -1 EBADF (Bad file descriptor)
) = -1 EBADF (Bad file descriptor)
/src/oss/strace-code/strace: Can't initiate libunwind: No such process
> ...
> /usr/lib/libevent_openssl-2.1.so.4.0.0(_init+0xfee) [0x2cfe]
> /usr/lib/libevent-2.1.so.4.0.0(bufferevent_setfd+0x3b) [0x16d9b]
> /usr/lib/libevent-2.1.so.4.0.0(evhttp_connection_connect_+0x14c) [0x39f6c]
> /usr/lib/libevent-2.1.so.4.0.0(event_free+0x3fe) [0x1fd1e]
> /usr/lib/libevent-2.1.so.4.0.0(event_base_loop+0x407) [0x20677]
/src/oss/strace-code/strace: Exit of unknown pid 28186 seen
[warn] Epoll ADD(4) on fd 5 failed. Old events were 0; read change was 0 (none); write change was 1 (add); close change was 0 (none): Bad file descriptor
<getaddrinfo traces trimmed>
close(5) = -1 EBADF (Bad file descriptor)
) = -1 EBADF (Bad file descriptor)
/src/oss/strace-code/strace: Can't initiate libunwind: No such process
> /lib/x86_64-linux-gnu/libpthread-2.19.so(__close_nocancel+0x7) [0xeb20]
> /usr/lib/libevent-2.1.so.4.0.0(evhttp_connection_reset_+0x55) [0x373f5]
> /usr/lib/libevent-2.1.so.4.0.0(evhttp_connection_fail_+0xc1) [0x3aed1]
> /usr/lib/libevent-2.1.so.4.0.0(evhttp_connection_fail_+0x4a3) [0x3b2b3]
> /usr/lib/libevent-2.1.so.4.0.0(bufferevent_enable+0x192) [0x16722]
> /usr/lib/libevent-2.1.so.4.0.0(event_free+0x5df) [0x1feff]
> /usr/lib/libevent-2.1.so.4.0.0(event_base_loop+0x407) [0x20677]
/src/oss/strace-code/strace: Exit of unknown pid 28187 seen
some request failed - no idea which one though!
socket error = Bad file descriptor (9)
Before this patch:
$ sample/https-client -retries 1 -url https://libevent.org
[warn] Epoll ADD(1) on fd 6 failed. Old events were 0; read change was 1 (add); write change was 0 (none); close change was 0 (none): Bad file descriptor
[warn] Epoll ADD(4) on fd 6 failed. Old events were 0; read change was 0 (none); write change was 1 (add); close change was 0 (none): Bad file descriptor
some request failed - no idea which one though!
socket error = Bad file descriptor (9)
After this patch:
$ sample/https-client -retries 1 -url https://libevent.org
Response line: 0 (null)
Reported-by: gerkenjohannes@web.de
|
|
d9da8443
|
2014-09-21T18:36:29
|
|
https-client: add -retries argument, for connection retries
Using evhttp_connection_set_retries() API.
|
|
07b5e45b
|
2014-09-18T15:08:57
|
|
Merge remote-tracking branch 'origin/patches-2.0'
|
|
b34e4ac3
|
2014-09-12T14:19:14
|
|
[Bugfix] fix bufferevent setwatermark suspend_read
|
|
89c1a3b7
|
2014-09-18T12:40:38
|
|
Fix several memory leaks in the unit tests.
Also add a comment to buffer.c about why we call
evbuffer_file_segment_free on failure to add the segment.
|
|
364c1106
|
2014-09-18T12:12:36
|
|
Fix for a677b72bd6d9d378daf9775966aa8ca574e26e67
|
|
fb57b8ba
|
2014-09-18T12:08:50
|
|
Make a buffer larger in the tests to avoid a scary evbuffer_copyout_from()
The call was safe, but coverity couldn't tell. CID 1239294.
|
|
ca5b5c7d
|
2014-09-18T12:04:16
|
|
Use a more precise calculation for max in time-ratelim.c
CID 1239297
|
|
a677b72b
|
2014-09-18T12:02:13
|
|
Use evutil_weakrand() in unit tests.
(Coverity doesn't like random() or rand(). We don't care; this is
for unit tests.)
Fixes CID 1239298, 1239296, 1239295, 1239293.
|
|
76643dd0
|
2014-09-18T11:54:39
|
|
Fix a c90 warning
|
|
c119f241
|
2014-09-18T11:54:04
|
|
Fix a dead-code warning in unit tests. CID 1193548
|
|
37390574
|
2014-09-18T11:52:16
|
|
Fix a use-after-free in unit tests. CID 752027
|
|
c243dbf4
|
2014-09-18T11:44:11
|
|
Merge pull request #168 from ufo2243/master
make bufferevent_getwatermark api more robust
|
|
c8c7fa3a
|
2014-09-18T11:41:18
|
|
Merge pull request #119 from ldx/winhosts
Fix hosts file use on Windows.
|
|
3cc0eace
|
2014-09-16T22:25:52
|
|
Fix use-after-free error in EV_CLOSURE_EVENT callback
|
|
35f107de
|
2014-09-18T11:36:08
|
|
Merge remote-tracking branch 'origin/patches-2.0'
|
|
79800df7
|
2014-03-25T13:35:13
|
|
regress_buffer: fix 'memcmp' compare size
|
|
73615a37
|
2014-09-18T11:31:52
|
|
Merge pull request #118 from azat/http-forward-family-to-bufferevent
Add evhttp_connection_set_family() to set addrinfo->family for DNS requests
|
|
08c88ea5
|
2014-09-18T11:28:19
|
|
use correct tt macro for pointer compare
|
|
afce2721
|
2014-09-18T11:25:27
|
|
Merge pull request #128 from azat/tests-disable-when-inactive-v5
Some tests for EVDNS_BASE_DISABLE_WHEN_INACTIVE flag
|