Imported Upstream version 1.8.7
[debian/sudo] / compat / strlcpy.c
index 89fb01b0b6401f654359833fd451da71df13ffab..765bde84ea15376d0c1b06856d0334f7b1934a8b 100644 (file)
@@ -1,7 +1,7 @@
 /*     $OpenBSD: strlcpy.c,v 1.5 2001/05/13 15:40:16 deraadt Exp $     */
 
 /*
- * Copyright (c) 1998, 2003-2005, 2010-2011
+ * Copyright (c) 1998, 2003-2005, 2010-2011, 2013
  *     Todd C. Miller <Todd.Miller@courtesan.com>
  *
  * Permission to use, copy, modify, and distribute this software for any
@@ -19,6 +19,8 @@
 
 #include <config.h>
 
+#ifndef HAVE_STRLCPY
+
 #include <sys/types.h>
 
 #include "missing.h"
@@ -53,3 +55,4 @@ strlcpy(char *dst, const char *src, size_t siz)
 
        return s - src - 1;     /* count does not include NUL */
 }
+#endif /* HAVE_STRLCPY */