projects
/
docbot.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
8f264af
)
- add a default for maximum number of results
author
Andreas 'ads' Scherbaum
<ads@pgug.de>
Fri, 9 Mar 2012 20:52:32 +0000
(21:52 +0100)
committer
Andreas 'ads' Scherbaum
<ads@pgug.de>
Fri, 9 Mar 2012 20:52:32 +0000
(21:52 +0100)
docbot.pl
patch
|
blob
|
blame
|
history
diff --git
a/docbot.pl
b/docbot.pl
index 8b34ef590fcf4d0a8e37a2aaa91492852cd78587..3d657eab650fae8dc83b5f122290cad7fe6824ce 100755
(executable)
--- a/
docbot.pl
+++ b/
docbot.pl
@@
-1833,6
+1833,10
@@
sub handle_command_search {
my @lines = ();
my $maxresults = config_get_key2('search', 'maxresults');
+ if ($maxresults == 0) {
+ # set a reasonable high default
+ $maxresults = 50;
+ }
my $maxwrap = config_get_key2('search', 'maxwrap');
for (my $a = 1; $a <= int($maxresults / $maxwrap); $a++) {
my @line = ();