progname: also set global program_invocation_name, when possible.
[gnulib.git] / tests / test-memrchr.c
index 84f6c5b..63568c1 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * Copyright (C) 2008 Free Software Foundation
+ * Copyright (C) 2008-2009 Free Software Foundation
  * Written by Eric Blake and Bruno Haible
  *
  * This program is free software: you can redistribute it and/or modify
@@ -22,6 +22,8 @@
 #include <stdio.h>
 #include <stdlib.h>
 
+#include "zerosize-ptr.h"
+
 #define ASSERT(expr) \
   do                                                                        \
     {                                                                       \
@@ -56,7 +58,7 @@ main ()
   ASSERT (MEMRCHR (input, 'a', n) == input + n - 1);
 
   ASSERT (MEMRCHR (input, 'a', 0) == NULL);
-  ASSERT (MEMRCHR (NULL, 'a', 0) == NULL);
+  ASSERT (MEMRCHR (zerosize_ptr (), 'a', 0) == NULL);
 
   ASSERT (MEMRCHR (input, 'b', n) == input + n - 2);
   ASSERT (MEMRCHR (input, 'c', n) == input + n - 3);