mheily
68e94a12eb
Fix compilation issues on Solaris 10 with GCC 4.5
...
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@518 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-05-22 03:29:14 +00:00
mheily
5d11e7e930
- Build the static library with MAKE_STATIC to expose libkqueue_init().
...
- Build a statically-linked version of kqtest during 'make check'.
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@517 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-05-22 03:01:24 +00:00
mheily
0c2f0771b5
- Build two versions of the library: one for debugging, and one for release.
...
- Link kqtest against libkqueue_debug.so
- Build
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@516 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-05-22 02:44:16 +00:00
mheily
af270012fc
Another tracing_mutex_assert() fix
...
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@515 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-05-22 01:20:24 +00:00
mheily
140343f197
Fix tracing_mutex_assert() by tracking the thread ID of the lock owner and
...
behave properly when the mutex is held by another thread.
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@514 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-05-22 00:57:44 +00:00
mheily
54cafd9c68
Add -Wextra to CFLAGS and fix all related warnings on Linux.
...
This will also need to be done on Solaris.
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@513 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-05-22 00:28:35 +00:00
jocke
8f90bd7127
Updated Xcode project
...
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@512 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-05-20 05:47:20 +00:00
jocke
1f04856a80
Analogous knote locking logic compared to Linux implementation, now we don't fail assertions any more.
...
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@511 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-05-19 14:18:22 +00:00
jocke
68d14fabb0
Fix proper semantics for read events on Solaris, fixing kqtest failure. According to the original kqueue paper, such events should not be signaled (which is also tested by kqtest).
...
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@510 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-05-19 13:38:37 +00:00
jocke
c1e6d52fcf
Match signed type of 'filt' coming in (alternatively change line 175 and remove otherwise useless comparison < 0).
...
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@509 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-05-19 07:36:55 +00:00
jocke
e6543c4c39
Avoid possible overrun of sigtbl[] if signal would be == SIGNAL_MAX.
...
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@508 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-05-19 07:35:47 +00:00
marius
90aa7efe71
* Fixed a compiler warning when using clang on Ubuntu 11.04
...
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@507 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-05-14 11:49:21 +00:00
mheily
4a2789f45e
Make knote_lock() and knote_unlock() macros again, so the assert() will provide useful information
...
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@506 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-05-10 02:51:59 +00:00
mheily
ea83addadb
- Fix a use-after-free bug with EV_ONESHOT that was introduced in r494.
...
- Test for incorrect usage of knote_lock() and knote_unlock()
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@505 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-05-10 02:34:24 +00:00
mheily
4c4a1b9b03
Fix the 'make debug' target under Windows.
...
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@504 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-05-10 01:59:38 +00:00
mheily
c9f509e34f
- Fix compilation issues on MinGW.
...
- Improve error handling in test/read.c
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@503 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-05-10 01:30:02 +00:00
marius
6fb331d9b7
Fixed a bug in the static build option in CMakeLists.txt
...
Made some symbols unique w.r.t. libpthread_workqueue to prevent duplicate symbols when linking as static libs
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@502 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-05-09 19:05:49 +00:00
marius
e04070c63b
Removed unused/unneeded evt_loop implementation
...
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@501 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-05-09 19:04:31 +00:00
marius
699bb19e76
Fixed some mistakes within the CMakeLists.txt
...
Made latest revision compatible to windows again
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@500 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-05-04 17:39:25 +00:00
mheily
bc9c93a130
Remove www/ directory, since the website is now managed by Trac
...
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@499 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-05-01 20:25:07 +00:00
mheily
87371cda36
Test commit using new hook
...
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@498 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-04-30 18:21:51 +00:00
mheily
f8bee50516
Remove TODO items
...
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@497 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-04-30 17:59:30 +00:00
mheily
2aff28d85a
Various fixes for Windows.
...
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@496 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-04-30 04:19:08 +00:00
mheily
0f356c8932
Improvements to EVFILT_READ on Windows.
...
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@495 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-04-29 23:47:51 +00:00
mheily
5933ba024c
Use tracing_mutex_t instead of pthread_mutex_t for knote and kqueue locks.
...
Fix a locking bug in Linux kevent_copyout().
Fix and enable the knote_lock() and knote_unlock() macros.
Implement tracing_mutex_destroy().
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@494 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-04-29 03:59:59 +00:00
mheily
e138f4a4c9
Add tracing mutexes to debug.h.
...
/*
* Tracing mutexes are a thin wrapper around the pthread_mutex_t
* datatype that tracks and reports when a mutex is locked or unlocked.
* It also allows you to assert that a mutex has (or has not) been locked
* by calling tracing_mutex_assert().
*/
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@493 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-04-29 03:28:07 +00:00
marius
c4573236fa
Some changes to the 'new' ref-count mechanism of knote - please elaborate
...
Fixed a race condition within windows timers using the ref count mechanism
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@492 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-04-28 12:01:04 +00:00
mheily
fcc95e5a18
Re-enable the knote mutex and reference counter.
...
Improve the knote reference counting mechanism.
New function knote_delete().
Rename 'flags' to 'kn_flags' in struct knote.
Rename 'mtx' to 'kn_mtx' in struct knote.
Rename 'kntree_ent' to 'kn_entries' in struct knote.
Add a knote flag named 'KNFL_KNOTE_DELETED' to indicate that a knote has been deleted. With reference counting, this becomes necessary.
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@491 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-04-27 03:30:31 +00:00
marius
731410fef0
EVFILT_USER implementation on windows
...
Change VS Solution structure to be more well-arranged
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@490 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-04-26 20:12:28 +00:00
marius
3ea5de4571
Updated VS Solution and CMakeLists.txt to reflect latest changes
...
Added annotation to timer bug on windows
Fixed a wrong visibility in the static build of libkqueue
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@489 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-04-26 19:26:38 +00:00
mheily
4f0126ebc8
Commit a missing file that was accidentally ommited.
...
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@488 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-04-25 23:21:07 +00:00
mheily
1b4e9d4af8
Partial implementation of EVFILT_READ on Windows.
...
Switch to using IOCP as the synchronization mechanism on Windows instead of emulating pthread condition variables.
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@487 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-04-25 02:50:54 +00:00
mheily
04ca8661f7
Change the EVFILT_READ test to use TCP sockets instead of UNIX domain sockets,
...
so the tests can be run on Windows.
Fix a bug on Linux where epoll() will not return EPOLLHUP when a TCP socket
is closed. Instead, it will return POLLIN with zero bytes in the protocol
buffer.
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@486 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-04-24 02:56:17 +00:00
mheily
9bbb71b801
Fix various build issues on MinGW.
...
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@485 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-04-23 18:27:10 +00:00
mheily
74b37975ae
By default, kevent() will serialize the copyout() and copyin() functions so that only one thread can operate on a kevent structure. This is controlled by the SERIALIZE_KEVENT macro. This temporarily
...
restores the behavior from libkqueue 1.0 to give us time to implement
fine-grained locking properly.
New functions: kqueue_lock() and kqueue_unlock().
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@484 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-04-18 01:41:26 +00:00
marius
86b1fbb760
EVTFILT_TIMER working on windows
...
Added binary files on windows to svn:ignore
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@483 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-04-17 19:34:34 +00:00
marius
dc2761332f
Added CMakeLists.txt for libkqueue and tests
...
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@482 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-04-16 08:57:12 +00:00
marius
c4a997e8d5
Add option for static library build activated by defining MAKE_STATIC
...
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@481 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-04-16 08:54:17 +00:00
mheily
89f858788f
Testing SVN post-commit hook
...
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@480 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-04-14 01:12:48 +00:00
mheily
cee1de5c60
Test commit, trying a post-commit email notify hook
...
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@479 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-04-14 00:58:03 +00:00
mheily
252e29883a
Test commit, trying a post-commit email notify hook
...
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@478 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-04-14 00:56:09 +00:00
mheily
d417316168
Document test failure on SunOS
...
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@477 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-04-14 00:53:06 +00:00
mheily
a00bd06d97
Use calloc() instead of malloc() to avoid the use of uninitialized memory.
...
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@476 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-04-14 00:42:11 +00:00
mheily
650452c28f
Fix format string type mismatch
...
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@475 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-04-14 00:25:27 +00:00
mheily
09aa72ecd1
Provide missing atomic_ptr_cas definition on some platforms.
...
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@474 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-04-14 00:21:11 +00:00
marius
9abd0fc49c
Made libkqueue compile on windows again - functionality still broken on this platform
...
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@473 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-04-13 17:35:34 +00:00
marius
0abf2a781a
Fixed a bug within kevent_copyin_one() causing a knote mutex to be used after releasing the knote
...
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@472 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-04-13 17:24:19 +00:00
marius
3a1f03e6ae
Added clean initialization and destruction to mutex used within a knote.
...
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@471 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-04-13 17:23:13 +00:00
marius
0fb0ab9c2b
Test commit as marius@
...
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@470 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-04-13 01:14:30 +00:00
mheily
e045e4a70c
Fix incorrect "nfds" argument supplied to pselect(2)
...
git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@469 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
2011-04-11 03:17:37 +00:00