source@mandoc.bsd.lv
 help / color / mirror / Atom feed
* mdocml: without search results, skip the processing loops and the parser
@ 2014-08-23 22:26 schwarze
  0 siblings, 0 replies; only message in thread
From: schwarze @ 2014-08-23 22:26 UTC (permalink / raw)
  To: source

Log Message:
-----------
without search results, skip the processing loops and the parser

Modified Files:
--------------
    mdocml:
        main.c

Revision Data
-------------
Index: main.c
===================================================================
RCS file: /usr/vhosts/mdocml.bsd.lv/cvs/mdocml/main.c,v
retrieving revision 1.186
retrieving revision 1.187
diff -Lmain.c -Lmain.c -u -p -r1.186 -r1.187
--- main.c
+++ main.c
@@ -283,6 +283,14 @@ main(int argc, char *argv[])
 		manpath_free(&paths);
 		resp = res;
 
+		if (sz == 0) {
+			if (search.argmode == ARG_NAME)
+				fprintf(stderr, "%s: No entry for %s "
+				    "in the manual.\n", progname, argv[0]);
+			rc = MANDOCLEVEL_BADARG;
+			goto out;
+		}
+
 		/*
 		 * For standard man(1) and -a output mode,
 		 * prepare for copying filename pointers
--
 To unsubscribe send an email to source+unsubscribe@mdocml.bsd.lv

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2014-08-23 22:26 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-08-23 22:26 mdocml: without search results, skip the processing loops and the parser schwarze

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).