[FFmpeg-cvslog] avformat/utils: fix logic error in ff_mkdir_p

Peter Ross git at videolan.org
Tue Feb 15 23:24:28 EET 2022


ffmpeg | branch: master | Peter Ross <pross at xvid.org> | Tue Jan 25 18:28:32 2022 +1100| [6474300dc4212486eff82470061118cef720b420] | committer: Peter Ross

avformat/utils: fix logic error in ff_mkdir_p

Fix ticket# 9605

Signed-off-by: Peter Ross <pross at xvid.org>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=6474300dc4212486eff82470061118cef720b420
---

 libavformat/utils.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavformat/utils.c b/libavformat/utils.c
index cee86ae87b..ca61a97759 100644
--- a/libavformat/utils.c
+++ b/libavformat/utils.c
@@ -1136,7 +1136,7 @@ int ff_mkdir_p(const char *path)
         }
     }
 
-    if ((*(pos - 1) != '/') || (*(pos - 1) != '\\')) {
+    if ((*(pos - 1) != '/') && (*(pos - 1) != '\\')) {
         ret = mkdir(temp, 0755);
     }
 



More information about the ffmpeg-cvslog mailing list