Let's try -fanalyzer.

git-svn-id: https://www.unprompted.com/svn/projects/tildefriends/trunk@4431 ed5197a5-7fde-0310-b194-c3ffbd925b24
This commit is contained in:
2023-08-25 20:57:55 +00:00
parent dcea08f73b
commit daeb88785d
7 changed files with 48 additions and 41 deletions

View File

@ -1136,8 +1136,8 @@ static JSValue _tf_ssb_hmacsha256_verify(JSContext* context, JSValueConst this_v
const char* signature = JS_ToCStringLen(context, &signature_length, argv[2]);
const char* public_key_start = public_key && *public_key == '@' ? public_key + 1 : public_key;
const char* public_key_end = strstr(public_key_start, ".ed25519");
if (!public_key_end)
const char* public_key_end = public_key_start ? strstr(public_key_start, ".ed25519") : NULL;
if (public_key_start && !public_key_end)
{
public_key_end = public_key_start + strlen(public_key_start);
}