Adding temporary fix to "glutInitDisplayString" to ignore numerical assignments
git-svn-id: https://svn.code.sf.net/p/freeglut/code/trunk@701 7f0cb862-5218-0410-a997-914c9d46530a
This commit is contained in:
parent
4f6e4144b1
commit
2c85792a59
@ -1207,3 +1207,7 @@ and "freeglut"
|
|||||||
(312) Added multisampling support for *nix and Windows; some other pixel
|
(312) Added multisampling support for *nix and Windows; some other pixel
|
||||||
format changes for Windows
|
format changes for Windows
|
||||||
|
|
||||||
|
(313) Added Markus Henschel's change (e-mail to developers' list, June 28,
|
||||||
|
2006) to have the "glutInitDisplayString" ignore numerical assignments to
|
||||||
|
tokens as a temporary fix.
|
||||||
|
|
||||||
|
@ -727,9 +727,16 @@ void FGAPIENTRY glutInitDisplayString( const char* displayMode )
|
|||||||
{
|
{
|
||||||
/* Process this token */
|
/* Process this token */
|
||||||
int i ;
|
int i ;
|
||||||
|
|
||||||
|
/* Temporary fix: Ignore any length specifications and at least
|
||||||
|
* process the basic token
|
||||||
|
* TODO: Fix this permanently
|
||||||
|
*/
|
||||||
|
size_t cleanlength = strcspn ( token, "=<>~!" );
|
||||||
|
|
||||||
for ( i = 0; i < NUM_TOKENS; i++ )
|
for ( i = 0; i < NUM_TOKENS; i++ )
|
||||||
{
|
{
|
||||||
if ( strcmp ( token, Tokens[i] ) == 0 ) break ;
|
if ( strncmp ( token, Tokens[i], cleanlength ) == 0 ) break ;
|
||||||
}
|
}
|
||||||
|
|
||||||
switch ( i )
|
switch ( i )
|
||||||
|
Reference in New Issue
Block a user