Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 5 Apr 2019 19:42:54 +0000 (UTC)
From:      Phil Shafer <phil@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r345967 - head/contrib/libxo/libxo
Message-ID:  <201904051942.x35JgsO7096850@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: phil
Date: Fri Apr  5 19:42:54 2019
New Revision: 345967
URL: https://svnweb.freebsd.org/changeset/base/345967

Log:
  Emergency fix for NULL deref in xo_xml_leader_len

Modified:
  head/contrib/libxo/libxo/libxo.c

Modified: head/contrib/libxo/libxo/libxo.c
==============================================================================
--- head/contrib/libxo/libxo/libxo.c	Fri Apr  5 19:32:26 2019	(r345966)
+++ head/contrib/libxo/libxo/libxo.c	Fri Apr  5 19:42:54 2019	(r345967)
@@ -600,7 +600,7 @@ xo_no_setlocale (void)
 static const char *
 xo_xml_leader_len (xo_handle_t *xop, const char *name, xo_ssize_t nlen)
 {
-    if (isalpha(name[0]) || name[0] == '_')
+    if (name == NULL || isalpha(name[0]) || name[0] == '_')
         return "";
 
     xo_failure(xop, "invalid XML tag name: '%.*s'", nlen, name);



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201904051942.x35JgsO7096850>