]> git.ozlabs.org Git - ccan/blobdiff - ccan/take/_info
cast, str, take, tal/grabfile, tal/str, typesafe_cb: use argc
[ccan] / ccan / take / _info
index 34b0886102c8e835cb0649a1fc378559f20db3de..fcb4f318a36ad77fdf1e7e8440de463b4f2d51cf 100644 (file)
@@ -1,5 +1,6 @@
-#include <string.h>
 #include "config.h"
+#include <stdio.h>
+#include <string.h>
 
 /**
  * take - routines to mark pointers to be consumed by called functions.
@@ -12,7 +13,7 @@
  * License: CC0 (Public domain)
  *
  * Example:
- *     // Given foo/bar.c outputs basename is bar.c
+ *     // Given "foo/bar.c" outputs basename is bar.c
  *     #include <ccan/take/take.h>
  *     #include <string.h>
  *
@@ -36,7 +37,7 @@
  *     {
  *             char *b;
  *
- *             if (argv[1]) // Mangle in place.
+ *             if (argc > 1) // Mangle in place.
  *                     b = base(take(argv[1]));
  *             else
  *                     b = base("test/string");