Commit graph

63 commits

Author SHA1 Message Date
Török Edvin
1d60f70d03 git-* commands are gone, use 'git svn'.
correct include position for fdpassing.h

git-svn: trunk@4813
2009-02-17 19:40:17 +00:00
Török Edvin
537292a773 Reject new commands sent as new-style commands to avoid confusion.
This means that IDSESSION/INSTREAM must be sent as nIDSESSION\n or zIDSESSION\0,
ditto for INSTREAM.
Adjust testcases accordingly.
Old commands are still accepted when sent without delimiter.

git-svn: trunk@4811
2009-02-17 18:04:48 +00:00
Török Edvin
e114b109c4 fix use of uninitialized value.
add test for STREAM.
fix missing closing pragmas.

git-svn: trunk@4810
2009-02-17 17:35:31 +00:00
Török Edvin
b337768f27 another warning
git-svn: trunk@4809
2009-02-17 16:07:58 +00:00
Török Edvin
c5355aedbd make sending ancillary data at wrong time a protocol error.
change testcase accordingly.

git-svn: trunk@4805
2009-02-17 15:59:31 +00:00
Török Edvin
5f6edb222c ReadTimeout handling, and introduce CommandReadTimeout.
git-svn: trunk@4803
2009-02-17 15:59:21 +00:00
Török Edvin
456e31a3cb fix typo.
add another stress test.
Don't leak file descriptors.
Fix IDSESSION delimiter handling.

git-svn: trunk@4800
2009-02-16 21:27:22 +00:00
Török Edvin
0378a9ab77 introduce timeouts for send(), this is needed for IDSESSION to work reliably,
since a buggy client implementation may get stuck in send(), and then clamd
gets stuck in send() -> deadlock. To avoid this we need nonblocking sockets, and
(low) timeouts on send.
Add more tests for clamd protocol, including a stress test for IDSESSION.

git-svn: trunk@4798
2009-02-16 18:27:08 +00:00
Török Edvin
ec86878226 test for FILDES
git-svn: trunk@4797
2009-02-16 18:27:03 +00:00
Török Edvin
4e24a36173 add more unit tests.
Make handling of old-style commands compatible with old clamd: if they have a \n
that will delimit the command.
If multiscan of a single file encounters errors, don't reply OK too.

git-svn: trunk@4796
2009-02-16 18:26:58 +00:00
Török Edvin
6870ebe176 mdprintf was also taking %f and %l, and they have different size than int.
Make the ARGLEN get the correct vaarg types, otherwise it was popping off the
stack an item of the wrong size!

git-svn: trunk@4784
2009-02-13 16:52:15 +00:00
Török Edvin
8cad8e8323 fix distcheck errors
git-svn: trunk@4764
2009-02-12 18:25:17 +00:00
Török Edvin
05a213b850 add another missing file
git-svn: trunk@4763
2009-02-12 18:22:19 +00:00