mesa: Fix bogus strncmp
authorIan Romanick <ian.d.romanick@intel.com>
Tue, 24 May 2016 17:10:40 +0000 (10:10 -0700)
committerIan Romanick <ian.d.romanick@intel.com>
Wed, 1 Jun 2016 18:11:25 +0000 (11:11 -0700)
commit049bb94d2e177f7415e7dddd71907be3e7f153c6
treea9eed4142d10cee580acd8f2d4cac01ad8c75a07
parent12740efd29a4b17b721e4ca157ad3ae714c70842
mesa: Fix bogus strncmp

The string "[0]\0" is the same as "[0]" as far as the C string datatype
is concerned.  That string has length 3.  strncmp(s, length_3_string, 4)
is the same as strcmp(s, length_3_string), so make it be strcmp.

v2: Not the same as strncmp(..., 3).  Noticed by Ilia.

Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Samuel Iglesias Gonsálvez <siglesias@igalia.com>
Cc: "12.0" <mesa-stable@lists.freedesktop.org>
src/mesa/main/shader_query.cpp