aboutsummaryrefslogtreecommitdiff
path: root/lib/gssapi/mech/gss_mech_switch.c
diff options
context:
space:
mode:
authorCy Schubert <cy@FreeBSD.org>2023-01-06 20:48:22 +0000
committerCy Schubert <cy@FreeBSD.org>2023-01-06 20:48:22 +0000
commit6f4e10db3298f6d65e1e646fe52aaafc3682b788 (patch)
tree0a8de0ec1173c00886bcde1c3b18e0963e5f2b83 /lib/gssapi/mech/gss_mech_switch.c
parentd5d1e8b157da7410fe13e6302f8e1bee81320bb5 (diff)
Diffstat (limited to 'lib/gssapi/mech/gss_mech_switch.c')
-rw-r--r--lib/gssapi/mech/gss_mech_switch.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/gssapi/mech/gss_mech_switch.c b/lib/gssapi/mech/gss_mech_switch.c
index 58b187eda296..4d7f298d1961 100644
--- a/lib/gssapi/mech/gss_mech_switch.c
+++ b/lib/gssapi/mech/gss_mech_switch.c
@@ -137,6 +137,8 @@ _gss_string_to_oid(const char* s, gss_OID oid)
}
}
}
+ if (byte_count == 0)
+ return EINVAL;
if (!res) {
res = malloc(byte_count);
if (!res)