Commit Graph

1678 Commits

Author SHA1 Message Date
Jeremy Lakeman
6599835331 Squelch debug log message 2012-11-16 13:20:32 +10:30
Andrew Bettison
21a0f31ae4 Merge branch 'whacktmps' into 'master' 2012-11-15 13:41:45 +10:30
Andrew Bettison
6395f757cc Fix bugs in earlier conf/log recursion logic
Reinstate better recursion control in conf.c, remove from log.c.

Add <kludge> comment to "config set" code, add the same kludge to "config
del".
2012-11-15 12:38:17 +10:30
Andrew Bettison
f2d6c6d522 Kludge "config set" to fix Batphone upgrade bug 2012-11-14 13:16:23 +10:30
Andrew Bettison
9c69eaca1c Improve logic to avoid log/config infinite recursion
Put logic in log.c, remove from conf.c.  Now messages logged while logging
another message will get appended to the log buffer, and eventually flushed.
2012-11-14 13:16:23 +10:30
Jeremy Lakeman
7c6cdac1b2 Improve command line usage information 2012-11-14 12:27:47 +10:30
Jeremy Lakeman
10bde11918 Remove resolution of peer details from node info command 2012-11-14 12:17:41 +10:30
Jeremy Lakeman
dd93f201e3 Add separate reverse lookup command 2012-11-14 12:17:14 +10:30
Andrew Bettison
b66d8d6c5b Fix bug in 'rhizome direct pull'
Was not fetching payload of remote bundle, just manifest.  The problem was
caused by a change of logic recently to not activate any queued fetch
candidates immediately, but wait until the next fd_poll(), so that parsing a
single packetful of rhizome advertisments would start fetching the most
important one first, instead of the first one parsed.
2012-11-12 16:24:38 +10:30
Jeremy Lakeman
2993ee46c7 Move rhizome fetch info message to end of transfer 2012-11-12 15:35:53 +10:30
Jeremy Lakeman
93ee6b3fc8 Don't kill the interface for unreachable unicast peers 2012-11-12 14:46:09 +10:30
Andrew Bettison
b04564b6c9 Fix bug in 'rhizome list' command
Missing RETURN(), was using 'return' instead.
2012-11-12 14:38:50 +10:30
Andrew Bettison
70217a7e84 FATAL() macro calls abort() to provoke core dump 2012-11-12 14:38:50 +10:30
Andrew Bettison
cbc91d11e0 Improve performance timing diagnostics
Add __whence args to fd_func_enter() and fd_func_exit() so that their log
messages get reported from the location of the IN() or OUT() macro, not a line
in performance_timing.c.

Removed diagnostic information from the FATAL() message in fd_func_exit(), and
a comment explaining why (causes SEGV).
2012-11-12 14:38:50 +10:30
Jeremy Lakeman
3c69a45d42 Only respond with multiple matches if the key is the same 2012-11-12 11:12:21 +10:30
Jeremy Lakeman
9669cda2b2 Update expiry time on each add 2012-11-12 11:08:08 +10:30
Jeremy Lakeman
1a29082fea Fix warning 2012-11-12 10:41:16 +10:30
Jeremy Lakeman
f6ed8f1562 Fix segfaults 2012-11-12 10:38:24 +10:30
Jeremy Lakeman
c79c5d8968 Fix fetch process for manifests with the same payload, make sure failures don't get stuck in a loop 2012-11-09 15:57:06 +10:30
Jeremy Lakeman
25e99787df Dampen logging 2012-11-09 15:56:54 +10:30
Jeremy Lakeman
54e2d66934 Allow for with slightly longer paths 2012-11-09 13:40:55 +10:30
Jeremy Lakeman
42c501330c Intial notes for OpenBTS setup documentation 2012-11-08 15:15:52 +10:30
Andrew Bettison
3d55a019c0 Quieten some unconditional DEBUG messages 2012-11-08 10:23:57 +10:30
Andrew Bettison
5751569b59 Rhizome extract manifest to '-' writes to output
Instead of specifying a file path, if the file is given as '-' then the content
of the manifest is output in the 'manifest' key-value pair instead of written
to a file.
2012-11-07 20:29:12 +10:30
Andrew Bettison
b8de07679d Improve test framework: --line=N..M for assertGrep()
Support the --line option for assertGrep, assertStdoutGrep and assertStderrGrep
primitives to select a line or range of lines to which the grep will be
applied.
2012-11-07 20:27:11 +10:30
Andrew Bettison
00f9130f16 Get rid of unwanted DEBUG line 2012-11-07 17:27:40 +10:30
Andrew Bettison
5185c944c9 JNI interface returns byte[] instead of String
This allows the output fields of any command to contain nul characters, which
paves the way for extracting a manifest or other binary data directly instead
of having to write it into a temporary file.
2012-11-07 17:12:04 +10:30
Andrew Bettison
4450116472 Refactor string functions, add str_fromprint()
Move lots of non-Serval-specific string functions from "serval.h"/dataformats.c
to "str.h"/str.c.

Add str_fromprint() function that reverses the effect of toprint(): interprets
escape sequences in the source string "\n\t\r\0\xHH\\" and replaces them with a
single char in the destination string.
2012-11-07 16:42:45 +10:30
Andrew Bettison
a29f685bdd Fix assertion failure in new Rhizome fetch queue logic
Revealed by improved Rhizome stress test that uses wide range of file sizes.
2012-11-05 14:46:16 +10:30
Andrew Bettison
548b837d2a Rhizome stress test: increase timeout from 3 to 10 minutes 2012-11-05 14:45:23 +10:30
Andrew Bettison
54d0e49a1d Improve Rhizome test defs: bundle_received_by()
Introduce per-instance server cache directory and use it to suppress duplicate
log messages from bundle_received_by().
2012-11-05 14:43:57 +10:30
Andrew Bettison
2b5b7fa896 Improve test framework: tfw_nolog() 2012-11-05 14:43:07 +10:30
Andrew Bettison
1ee62b7587 Fix bug in test framework: local $njobs used by other function 2012-11-05 12:07:44 +10:30
Jeremy Lakeman
780daa3aa4 Prevent segfault for interfaces with no address 2012-11-01 14:00:18 +10:30
Jeremy Lakeman
b4b256a5ea Remove dead code 2012-11-01 11:22:47 +10:30
Andrew Bettison
03f71dcccf Improve rhizome stress test
Generate test files from 2KiB to 32MiB in size, instead of all about 13 bytes
in size.  Guess what?  Found a bug!
2012-10-31 18:17:06 +10:30
Andrew Bettison
d9fb8d7956 Refactor 'interfaces' config parsing
Use new "str.h" str_to_ll_scaled() function to implement parse_quantity().
2012-10-31 18:16:05 +10:30
Andrew Bettison
d38ce66c95 Improve test framework: create_file()
New executable in Makefile 'all' target: tfw_createfile.

New str.h function: str_to_ll_scaled().
2012-10-31 18:13:33 +10:30
Andrew Bettison
aba7e417c4 Remove README.WHYNOTSIPS
The text of this historical note has been transplanted in slightly improved
form into the Serval wiki VoMP page:

http://developer.servalproject.org/dokuwiki/doku.php?id=content:technologies:vomp
2012-10-31 10:14:58 +10:30
Andrew Bettison
3c7eb7b058 Add missing sqlite3_blob_close()
Fixes #33.
2012-10-30 16:12:40 +10:30
Andrew Bettison
934ae73a3d Minor improvements to INSTALL.md 2012-10-30 15:05:24 +10:30
Andrew Bettison
c3ef89acc1 Fix bug: "interfaces=+" not working
The logic was clobbered back in June in a refactor by Daniel.
2012-10-30 14:50:47 +10:30
Andrew Bettison
a1cc415a4f Move information from BUILD.txt into INSTALL.md
Also remove out of date TODO file, no longer relevant.
2012-10-30 14:49:50 +10:30
Andrew Bettison
7cae7f5324 Replace README.DUMMYNETS with doc/Servald-Configuration.md 2012-10-30 12:44:43 +10:30
Andrew Bettison
4da7e29b05 Fix README.md -- Markdown typo 2012-10-28 23:18:12 -07:00
Andrew Bettison
a3cdf3c942 Add README.md and INSTALL.md
Also capture some documentation of Serval Infrastructure services.
2012-10-29 16:43:27 +10:30
gardners
b23b28b16d Changed rhizome manifest signature block type code semantics to
allow signature blocks of 256 bytes, and to allow multiple
signature types with same length. #34
2012-10-29 16:07:42 +10:30
Jeremy Lakeman
a4b392d693 Don't include rhizome adverts in packets with voice frames 2012-10-29 13:10:20 +10:30
Jeremy Lakeman
8dd7a81c71 Remove unused variables 2012-10-29 13:05:03 +10:30
Jeremy Lakeman
de95bb3971 Gracefully disable rhizome if the database cannot be opened
- close database after every command line operation
- don't cache rhizome enabled configuration
- don't send advertisements unless the database is open and the web server is running
- don't provess advertisements unless the database is open
2012-10-29 13:05:03 +10:30