[FFmpeg-devel,6/7] hlsenc: Fix creation of final directory in path

Submitted by Mark Thompson on Oct. 17, 2017, 10:11 p.m.

Details

Message ID 20171017221159.2349-6-sw@jkqxz.net
State New
Headers show

Commit Message

Mark Thompson Oct. 17, 2017, 10:11 p.m.
Fixes #6752.
---
 libavformat/hlsenc.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Patch hide | download patch | download mbox

diff --git a/libavformat/hlsenc.c b/libavformat/hlsenc.c
index 418f153c6f..eba3aef567 100644
--- a/libavformat/hlsenc.c
+++ b/libavformat/hlsenc.c
@@ -207,7 +207,7 @@  static int mkdir_p(const char *path) {
         }
     }
 
-    if ((*(pos - 1) != '/') || (*(pos - 1) != '\\')) {
+    if ((*(pos - 1) != '/') && (*(pos - 1) != '\\')) {
         ret = mkdir(temp, 0755);
     }