summaryrefslogtreecommitdiff
path: root/net-irc/emech/files/emech-3.0.99_p20221123-fix-Wreturn-type.patch
blob: 0413a61dcad806f1271e162a93c214239d50aa98 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
QA warns about non-void functions returning no value. Both function are not used
anywhere in the code anyway.

Pascal Jäger <pascal.jaeger@leimstift.de> (2022-11-23)

--- a/src/spy.c
+++ b/src/spy.c
@@ -460,7 +460,7 @@ void end_redirect(void)
 char *urlhost(const char *url)
 {
 	char	copy[strlen(url)];
-	const char *end,*beg,*dst;
+	char *end,*beg,*dst;
 	int	n = 0;
 
 	beg = end = url;
@@ -481,6 +481,7 @@ char *urlhost(const char *url)
 		end++;
 	}
 	stringcpy_n(copy,beg,(end-beg));
+	return beg;
 #ifdef DEBUG
 	debug("(urlhost) host = %s\n",copy);
 #endif
--- a/src/toybox.c
+++ b/src/toybox.c
@@ -196,6 +196,7 @@ int read_bigcharset(char *fname)
 int read_ascii(char *rest)
 {
 	to_user_q(global_from,FMT_PLAIN,rest);
+	return (0);
 }
 
 #ifdef TRIVIA