artulab
projects
/
openbsd
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
7aaded8
)
Check stdrup() return value.
author
tobhe
<tobhe@openbsd.org>
Fri, 19 Nov 2021 21:16:25 +0000
(21:16 +0000)
committer
tobhe
<tobhe@openbsd.org>
Fri, 19 Nov 2021 21:16:25 +0000
(21:16 +0000)
sbin/iked/ocsp.c
patch
|
blob
|
history
diff --git
a/sbin/iked/ocsp.c
b/sbin/iked/ocsp.c
index
6c8898a
..
06d77af
100644
(file)
--- a/
sbin/iked/ocsp.c
+++ b/
sbin/iked/ocsp.c
@@
-1,4
+1,4
@@
-/* $OpenBSD: ocsp.c,v 1.2
1 2020/12/22 21:01:5
5 tobhe Exp $ */
+/* $OpenBSD: ocsp.c,v 1.2
2 2021/11/19 21:16:2
5 tobhe Exp $ */
/*
* Copyright (c) 2014 Markus Friedl
@@
-149,6
+149,10
@@
ocsp_connect(struct iked *env, struct imsg *imsg)
oc->oc_sh = sh;
oc->oc_path = path;
oc->oc_url = strdup(url);
+ if (oc->oc_url == NULL) {
+ log_warn("%s: strdup failed", SPI_SH(&sh, __func__));
+ goto done;
+ }
path = NULL;
log_debug("%s: connect(%s, %s)", __func__, host, port);