Commit 8fa9fd14daaef1c185a6751487bf26fe0b14e9f2

Stefan Sperling 2018-11-11T15:14:58

remove unnecessary cast

1
2
3
4
5
6
7
8
9
10
11
12
13
diff --git a/lib/error.c b/lib/error.c
index 7063a0b..1df8f21 100644
--- a/lib/error.c
+++ b/lib/error.c
@@ -58,7 +58,7 @@ got_error_msg(int code, const char *msg)
 		if (code == got_errors[i].code) {
 			err.code = code;
 			err.msg = msg;
-			return (const struct got_error *)&err;
+			return &err;
 		}
 	}