Add scratchbuf implementation

This should fill the requirements for "we need to loop over a lot of
strings that usually are small enough to remain on stack, but we want to
protect ourselves against huge strings not fitting in the static
buffer we estimated as sufficient"
diff --git a/testsuite/.gitignore b/testsuite/.gitignore
index 2b71a47..9d26b88 100644
--- a/testsuite/.gitignore
+++ b/testsuite/.gitignore
@@ -2,6 +2,7 @@
 *.la
 *.so
 /.dirstamp
+/test-scratchbuf
 /test-strbuf
 /test-array
 /test-util
@@ -20,6 +21,8 @@
 /test-tools
 /rootfs
 /stamp-rootfs
+/test-scratchbuf.log
+/test-scratchbuf.trs
 /test-strbuf.log
 /test-strbuf.trs
 /test-array.log