From 9fa9eb9ac7bf1d3de825ee25a8f0ae81b7b77896 Mon Sep 17 00:00:00 2001 From: Mathieu Arnold Date: Tue, 26 Jul 2016 16:51:15 +0000 Subject: Cleanup patches, a* categories. Rename them to follow the make makepatch naming, and regenerate them. With hat: portmgr Sponsored by: Absolight --- .../files/patch-plugins_ripperX__plugin-oggenc.c | 30 ++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 audio/ripperx/files/patch-plugins_ripperX__plugin-oggenc.c (limited to 'audio/ripperx/files/patch-plugins_ripperX__plugin-oggenc.c') diff --git a/audio/ripperx/files/patch-plugins_ripperX__plugin-oggenc.c b/audio/ripperx/files/patch-plugins_ripperX__plugin-oggenc.c new file mode 100644 index 000000000000..ddbb5d1d419e --- /dev/null +++ b/audio/ripperx/files/patch-plugins_ripperX__plugin-oggenc.c @@ -0,0 +1,30 @@ +--- plugins/ripperX_plugin-oggenc.c.orig 2006-12-10 07:13:15 UTC ++++ plugins/ripperX_plugin-oggenc.c +@@ -1,5 +1,3 @@ +-// strndup is a GNU extension: +-#define _GNU_SOURCE + #include + #include + #include +@@ -9,6 +7,21 @@ + #define OGG_OUTPUT_BUF_LENGTH 2048 + #define PRINTOUT_INTERVAL 0.5 + ++char ++*strndup(const char *string, size_t n) ++{ ++ char *ret = malloc(n + 1); ++ ++ if (ret == NULL) ++ return NULL; ++ ++ strncpy(ret, string, n); ++ ++ ret[n] = '\0'; ++ ++ return ret; ++} ++ + void + strip_shit(char* input, int len) { + int i; -- cgit v1.2.3