cast, str, take, tal/grabfile, tal/str, typesafe_cb: use argc
[ccan] / ccan / tal / grab_file / _info
index 68ad089b06f23d59e4ef318f0f107c76a9e50e87..056f10990b08111ce1ebdc6c66541c445d87c7d0 100644 (file)
@@ -18,6 +18,8 @@
  *     {
  *             char *file;
  *
+ *             if (argc > 2)
+ *                     err(1, "Takes 0 or 1 arguments");
  *             file = grab_file(NULL, argv[1]);
  *             if (!file)
  *                     err(1, "Could not read file %s", argv[1]);