ports/deskutils/xmdiary/scripts/nomalloc
Mikhail Teterin 80399d5d1a Use `patch -p0'' instead of `patch -p'' -- the latter invocation
is not working on -current for some reason and pkg-fallout is
unhappy.

Submitted by:	pkg-fallout@
2013-12-01 18:22:50 +00:00

15 lines
204 B
Bash

#!/bin/sh
for f in `find $1 -type f -name \*.\[ch\] -print | xargs grep -l malloc.h`
do
patch -p0 << END_OF_PATCH
+++ $f
@@ -10,1 +10,1 @@
-#include <malloc.h>
+#include <stdlib.h>
END_OF_PATCH
done