From e1ee741930349a4daaada29bd6ff4cbc0e313641 Mon Sep 17 00:00:00 2001 From: Rob Landley Date: Tue, 6 Jun 2017 13:21:03 -0500 Subject: Add comment explaining strend() --- lib/lib.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/lib.c b/lib/lib.c index d11c600e..ceb1bc7d 100644 --- a/lib/lib.c +++ b/lib/lib.c @@ -393,6 +393,8 @@ int unescape(char c) return (idx == -1) ? 0 : to[idx]; } +// If string ends with suffix return pointer to start of suffix in string, +// else NULL char *strend(char *str, char *suffix) { long a = strlen(str), b = strlen(suffix); -- cgit v1.2.3