| Summary: | strncmp with SDL_AUDIODRIVER? | ||
|---|---|---|---|
| Product: | SDL | Reporter: | Ryan C. Gordon <icculus> |
| Component: | audio | Assignee: | Ryan C. Gordon <icculus> |
| Status: | RESOLVED FIXED | QA Contact: | Sam Lantinga <slouken> |
| Severity: | trivial | ||
| Priority: | P2 | ||
| Version: | HG 1.2 | ||
| Hardware: | All | ||
| OS: | All | ||
Nope, it should probably be strcasecmp Ah, the 1.2 branch looks like it had some sort of "SDL_AUDIODRIVER=driver:3" syntax at one point, which explains the strncmp(). Anyhow, fixed in svn revision #2799 and #2800. --ryan. |
In src/audio/SDL_audio.c, SDL_AudioInit(), we do this: if (SDL_strncmp(bootstrap[i]->name, driver_name, SDL_strlen(bootstrap[i]->name)) == 0) { Is there any reason for the 'n' version of strcmp()? Is there a case where we'd want to accept "SDL_AUDIODRIVER=directx92u3-jf-2p9"? --ryan.