[PATCH] avformat/utils: fix logic error in ff_mkdir_p
Fix ticket# 9605 Signed-off-by: Peter Ross <pross@xvid.org> --- libavformat/utils.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavformat/utils.c b/libavformat/utils.c index e643821fc9..1164cebe68 100644 --- a/libavformat/utils.c +++ b/libavformat/utils.c @@ -1135,7 +1135,7 @@ int ff_mkdir_p(const char *path) } } - if ((*(pos - 1) != '/') || (*(pos - 1) != '\\')) { + if ((*(pos - 1) != '/') && (*(pos - 1) != '\\')) { ret = mkdir(temp, 0755); } -- 2.34.1 -- Peter (A907 E02F A6E5 0CD2 34CD 20D2 6760 79C5 AC40 DD6B)
On Tue, Jan 25, 2022 at 06:30:03PM +1100, Peter Ross wrote:
Fix ticket# 9605
Signed-off-by: Peter Ross <pross@xvid.org> --- libavformat/utils.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/libavformat/utils.c b/libavformat/utils.c index e643821fc9..1164cebe68 100644 --- a/libavformat/utils.c +++ b/libavformat/utils.c @@ -1135,7 +1135,7 @@ int ff_mkdir_p(const char *path) } }
- if ((*(pos - 1) != '/') || (*(pos - 1) != '\\')) { + if ((*(pos - 1) != '/') && (*(pos - 1) != '\\')) { ret = mkdir(temp, 0755); }
-- 2.34.1
-- Peter (A907 E02F A6E5 0CD2 34CD 20D2 6760 79C5 AC40 DD6B)
i will apply in a couple of days if no one objects. this closes ticket# 9605 (-Wlogical-op) -- Peter (A907 E02F A6E5 0CD2 34CD 20D2 6760 79C5 AC40 DD6B)
participants (1)
-
Peter Ross