Added regression test for drd's memory allocation replacement functions.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7894 a5019735-40e9-0310-863c-91ae7b9d1cf9
diff --git a/exp-drd/tests/memory_allocation.c b/exp-drd/tests/memory_allocation.c
new file mode 100644
index 0000000..ddb0b32
--- /dev/null
+++ b/exp-drd/tests/memory_allocation.c
@@ -0,0 +1,15 @@
+/* Repeatedly allocate and free memory. Tests whether drd */
+/* really frees memory allocated by a client. See also    */
+/* http://bugs.kde.org/show_bug.cgi?id=161036             */
+
+#include <stdlib.h>
+
+int main()
+{
+  int i;
+  for (i = 0; i < 100000; i++)
+  {
+    free(malloc(40960));
+  }
+  return 0;
+}