mirror of
https://gitlab.freedesktop.org/pulseaudio/pulseaudio.git
synced 2025-10-29 05:40:23 -04:00
module: Replace rindex() with strrchr()
rindex() appears to be "non-standard" to an extent, and it caused a build failure on mingw32. From the man page of rindex(): "POSIX.1-2008 removes the specifications of index() and rindex(), recommending strchr(3) and strrchr(3) instead."
This commit is contained in:
parent
588af08d25
commit
eab0544f23
1 changed files with 1 additions and 1 deletions
|
|
@ -67,7 +67,7 @@ bool pa_module_exists(const char *name) {
|
||||||
|
|
||||||
/* strip .so from the end of name, if present */
|
/* strip .so from the end of name, if present */
|
||||||
n = pa_xstrdup(name);
|
n = pa_xstrdup(name);
|
||||||
p = rindex(n, '.');
|
p = strrchr(n, '.');
|
||||||
if (p && pa_streq(p, PA_SOEXT))
|
if (p && pa_streq(p, PA_SOEXT))
|
||||||
p[0] = 0;
|
p[0] = 0;
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue