Commit 44a80897 authored by Limin Wang's avatar Limin Wang Committed by Michael Niedermayer

avutil/avstring: Fix warning: ISO C90 forbids mixed declarations and code

Signed-off-by: 's avatarLimin Wang <lance.lmwang@gmail.com>
Signed-off-by: 's avatarMichael Niedermayer <michael@niedermayer.cc>
parent 72a08af8
...@@ -258,15 +258,17 @@ char *av_strireplace(const char *str, const char *from, const char *to) ...@@ -258,15 +258,17 @@ char *av_strireplace(const char *str, const char *from, const char *to)
const char *av_basename(const char *path) const char *av_basename(const char *path)
{ {
char *p; char *p;
#if HAVE_DOS_PATHS
char *q, *d;
#endif
if (!path || *path == '\0') if (!path || *path == '\0')
return "."; return ".";
p = strrchr(path, '/'); p = strrchr(path, '/');
#if HAVE_DOS_PATHS #if HAVE_DOS_PATHS
char *q = strrchr(path, '\\'); q = strrchr(path, '\\');
char *d = strchr(path, ':'); d = strchr(path, ':');
p = FFMAX3(p, q, d); p = FFMAX3(p, q, d);
#endif #endif
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment