Imported Upstream version 1.8.7
[debian/sudo] / compat / getprogname.c
index 34673f5f69962264ff4e5303c9bb6c00ec01b701..6fa876d5522bd8e5d492b9d34763ce8ee1208bf1 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2010 Todd C. Miller <Todd.Miller@courtesan.com>
+ * Copyright (c) 2010, 2013 Todd C. Miller <Todd.Miller@courtesan.com>
  *
  * Permission to use, copy, modify, and distribute this software for any
  * purpose with or without fee is hereby granted, provided that the above
@@ -16,6 +16,8 @@
 
 #include <config.h>
 
+#if !defined(HAVE_GETPROGNAME) && !defined(HAVE___PROGNAME)
+
 #include <sys/types.h>
 
 #include <stdio.h>
@@ -44,3 +46,4 @@ getprogname(void)
 {
     return progname;
 }
+#endif /* !HAVE_GETPROGNAME !HAVE___PROGNAME */