File: libsx-strdup.diff

package info (click to toggle)
libsx 2.08-7
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 2,732 kB
  • sloc: ansic: 8,713; sh: 8,603; makefile: 63
file content (23 lines) | stat: -rw-r--r-- 533 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
Origin: libsx-2.05-18.fc12.src.rpm Fedora package
Description: Conditionally include strdup().

Index: libsx-2.08/src/freq.c
===================================================================
--- libsx-2.08.orig/src/freq.c
+++ libsx-2.08/src/freq.c
@@ -45,6 +45,7 @@ int view_pt = 0;
  *
  * Which is why they don't provide strdup() in their libc.  Gay or what?
  */
+#ifndef strdup
 char *strdup(const char *str)
 {
   char *new;
@@ -55,6 +56,7 @@ char *strdup(const char *str)
 
   return new;
 }
+#endif
 
 #endif /* ultrix */