Check token type before trying to match tokid. Fixes PR 12923.
[pspp] / src / data-in.c
index 0ce42fa652a4085fe457ba134e284c9767f5014a..8f36dcb046d298c3e431b59fc53617c939ca4113 100644 (file)
@@ -14,8 +14,8 @@
 
    You should have received a copy of the GNU General Public License
    along with this program; if not, write to the Free Software
-   Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
-   02111-1307, USA. */
+   Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+   02110-1301, USA. */
 
 #include <config.h>
 #include "data-in.h"
@@ -760,7 +760,7 @@ parse_enum (struct data_in *i, const char *what,
     if ((ep->can_abbreviate
          && lex_id_match_len (ep->name, strlen (ep->name), name, length))
         || (!ep->can_abbreviate && length == strlen (ep->name)
-            && !memcmp (name, ep->name, length)))
+            && !mm_case_compare (name, ep->name, length)))
       {
         *output = ep->value;
         return true;