aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Stenberg <daniel@haxx.se>2000-05-23 10:25:30 +0000
committerDaniel Stenberg <daniel@haxx.se>2000-05-23 10:25:30 +0000
commite92a10c36ff22f106677acb7540263b4a300497e (patch)
treec89164b9f4474d7a9f913961b19abeab4a51b11c
parent9b20d0a47fa16bab8356662bad307698b0eb27e7 (diff)
now splits the text into several puts() calls
-rw-r--r--src/mkhelp.pl9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/mkhelp.pl b/src/mkhelp.pl
index 842a42f59..a5877d5af 100644
--- a/src/mkhelp.pl
+++ b/src/mkhelp.pl
@@ -69,16 +69,25 @@ print "void hugehelp(void)\n";
print "{\n";
print "puts (\n";
+$outsize=0;
for(@out) {
chop;
$new = $_;
+ $outsize += length($new);
+
$new =~ s/\\/\\\\/g;
$new =~ s/\"/\\\"/g;
printf("\"%s\\n\"\n", $new);
+ if($outsize > 10000) {
+ # terminate and make another puts() call here
+ print ");\n puts(\n";
+ $outsize=0;
+ }
+
}
print " ) ;\n}\n"