Git Inbox Mirror of the ffmpeg-devel mailing list - see https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
 help / color / mirror / Atom feed
* [FFmpeg-devel] [PATCH 0/2] use av_fopen_utf8() instead of plain fopen()
@ 2022-05-07 17:39 ffmpegagent
  2022-05-07 17:39 ` [FFmpeg-devel] [PATCH 1/2] fftools: " softworkz
                   ` (2 more replies)
  0 siblings, 3 replies; 30+ messages in thread
From: ffmpegagent @ 2022-05-07 17:39 UTC (permalink / raw)
  To: ffmpeg-devel; +Cc: softworkz

Unify file access operations by replacing usages of direct calls to posix
fopen()

softworkz (2):
  fftools: use av_fopen_utf8() instead of plain fopen()
  avfilter: use av_fopen_utf8() instead of plain fopen()

 fftools/cmdutils.c            | 6 +++---
 fftools/ffmpeg.c              | 4 ++--
 fftools/opt_common.c          | 2 +-
 libavfilter/af_firequalizer.c | 2 +-
 libavfilter/vf_deshake.c      | 2 +-
 libavfilter/vf_signature.c    | 4 ++--
 libavfilter/vf_ssim.c         | 2 +-
 libavfilter/vf_vmafmotion.c   | 2 +-
 8 files changed, 12 insertions(+), 12 deletions(-)


base-commit: f3b7ba21ba49b32b4476a8c7c5a9bcdad15e3943
Published-As: https://github.com/ffstaging/FFmpeg/releases/tag/pr-ffstaging-26%2Fsoftworkz%2Fsubmit_replace_fopen-v1
Fetch-It-Via: git fetch https://github.com/ffstaging/FFmpeg pr-ffstaging-26/softworkz/submit_replace_fopen-v1
Pull-Request: https://github.com/ffstaging/FFmpeg/pull/26
-- 
ffmpeg-codebot
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

^ permalink raw reply	[flat|nested] 30+ messages in thread

* [FFmpeg-devel] [PATCH 1/2] fftools: use av_fopen_utf8() instead of plain fopen()
  2022-05-07 17:39 [FFmpeg-devel] [PATCH 0/2] use av_fopen_utf8() instead of plain fopen() ffmpegagent
@ 2022-05-07 17:39 ` softworkz
  2022-05-08 20:03   ` Martin Storsjö
  2022-05-07 17:39 ` [FFmpeg-devel] [PATCH 2/2] avfilter: " softworkz
  2022-05-09 18:52 ` [FFmpeg-devel] [PATCH v2] " softworkz
  2 siblings, 1 reply; 30+ messages in thread
From: softworkz @ 2022-05-07 17:39 UTC (permalink / raw)
  To: ffmpeg-devel; +Cc: softworkz

From: softworkz <softworkz@hotmail.com>

Signed-off-by: softworkz <softworkz@hotmail.com>
---
 fftools/cmdutils.c   | 6 +++---
 fftools/ffmpeg.c     | 4 ++--
 fftools/opt_common.c | 2 +-
 3 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/fftools/cmdutils.c b/fftools/cmdutils.c
index 5d7cdc3e10..ca3a4c267a 100644
--- a/fftools/cmdutils.c
+++ b/fftools/cmdutils.c
@@ -818,7 +818,7 @@ FILE *get_preset_file(char *filename, size_t filename_size,
 
     if (is_path) {
         av_strlcpy(filename, preset_name, filename_size);
-        f = fopen(filename, "r");
+        f = av_fopen_utf8(filename, "r");
     } else {
 #if HAVE_GETMODULEHANDLE && defined(_WIN32)
         char datadir[MAX_PATH], *ls;
@@ -842,13 +842,13 @@ FILE *get_preset_file(char *filename, size_t filename_size,
                 continue;
             snprintf(filename, filename_size, "%s%s/%s.ffpreset", base[i],
                      i != 1 ? "" : "/.ffmpeg", preset_name);
-            f = fopen(filename, "r");
+            f = av_fopen_utf8(filename, "r");
             if (!f && codec_name) {
                 snprintf(filename, filename_size,
                          "%s%s/%s-%s.ffpreset",
                          base[i], i != 1 ? "" : "/.ffmpeg", codec_name,
                          preset_name);
-                f = fopen(filename, "r");
+                f = av_fopen_utf8(filename, "r");
             }
         }
     }
diff --git a/fftools/ffmpeg.c b/fftools/ffmpeg.c
index a85ed18b08..a9bd4a790f 100644
--- a/fftools/ffmpeg.c
+++ b/fftools/ffmpeg.c
@@ -1261,9 +1261,9 @@ static void do_video_stats(OutputStream *ost, int frame_size)
 
     /* this is executed just the first time do_video_stats is called */
     if (!vstats_file) {
-        vstats_file = fopen(vstats_filename, "w");
+        vstats_file = av_fopen_utf8(vstats_filename, "w");
         if (!vstats_file) {
-            perror("fopen");
+            perror("av_fopen_utf8");
             exit_program(1);
         }
     }
diff --git a/fftools/opt_common.c b/fftools/opt_common.c
index c303db4d09..dda199d412 100644
--- a/fftools/opt_common.c
+++ b/fftools/opt_common.c
@@ -1178,7 +1178,7 @@ int init_report(const char *env, FILE **file)
     if (!envlevel)
         report_file_level = FFMAX(report_file_level, prog_loglevel);
 
-    report_file = fopen(filename.str, "w");
+    report_file = av_fopen_utf8(filename.str, "w");
     if (!report_file) {
         int ret = AVERROR(errno);
         av_log(NULL, AV_LOG_ERROR, "Failed to open report \"%s\": %s\n",
-- 
ffmpeg-codebot

_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

^ permalink raw reply	[flat|nested] 30+ messages in thread

* [FFmpeg-devel] [PATCH 2/2] avfilter: use av_fopen_utf8() instead of plain fopen()
  2022-05-07 17:39 [FFmpeg-devel] [PATCH 0/2] use av_fopen_utf8() instead of plain fopen() ffmpegagent
  2022-05-07 17:39 ` [FFmpeg-devel] [PATCH 1/2] fftools: " softworkz
@ 2022-05-07 17:39 ` softworkz
  2022-05-09 18:52 ` [FFmpeg-devel] [PATCH v2] " softworkz
  2 siblings, 0 replies; 30+ messages in thread
From: softworkz @ 2022-05-07 17:39 UTC (permalink / raw)
  To: ffmpeg-devel; +Cc: softworkz

From: softworkz <softworkz@hotmail.com>

Signed-off-by: softworkz <softworkz@hotmail.com>
---
 libavfilter/af_firequalizer.c | 2 +-
 libavfilter/vf_deshake.c      | 2 +-
 libavfilter/vf_signature.c    | 4 ++--
 libavfilter/vf_ssim.c         | 2 +-
 libavfilter/vf_vmafmotion.c   | 2 +-
 5 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/libavfilter/af_firequalizer.c b/libavfilter/af_firequalizer.c
index c19a2fe122..e1497dcef0 100644
--- a/libavfilter/af_firequalizer.c
+++ b/libavfilter/af_firequalizer.c
@@ -604,7 +604,7 @@ static int generate_kernel(AVFilterContext *ctx, const char *gain, const char *g
     if (ret < 0)
         return ret;
 
-    if (s->dumpfile && (!s->dump_buf || !s->analysis_rdft || !(dump_fp = fopen(s->dumpfile, "w"))))
+    if (s->dumpfile && (!s->dump_buf || !s->analysis_rdft || !(dump_fp = av_fopen_utf8(s->dumpfile, "w"))))
         av_log(ctx, AV_LOG_WARNING, "dumping failed.\n");
 
     vars[VAR_CHS] = inlink->ch_layout.nb_channels;
diff --git a/libavfilter/vf_deshake.c b/libavfilter/vf_deshake.c
index 4f28467bb2..dea69e11cd 100644
--- a/libavfilter/vf_deshake.c
+++ b/libavfilter/vf_deshake.c
@@ -353,7 +353,7 @@ static av_cold int init(AVFilterContext *ctx)
     }
 
     if (deshake->filename)
-        deshake->fp = fopen(deshake->filename, "w");
+        deshake->fp = av_fopen_utf8(deshake->filename, "w");
     if (deshake->fp)
         fwrite("Ori x, Avg x, Fin x, Ori y, Avg y, Fin y, Ori angle, Avg angle, Fin angle, Ori zoom, Avg zoom, Fin zoom\n", 1, 104, deshake->fp);
 
diff --git a/libavfilter/vf_signature.c b/libavfilter/vf_signature.c
index 4ca57ebf1d..904123fd4e 100644
--- a/libavfilter/vf_signature.c
+++ b/libavfilter/vf_signature.c
@@ -386,7 +386,7 @@ static int xml_export(AVFilterContext *ctx, StreamContext *sc, const char* filen
     FILE* f;
     unsigned int pot3[5] = { 3*3*3*3, 3*3*3, 3*3, 3, 1 };
 
-    f = fopen(filename, "w");
+    f = av_fopen_utf8(filename, "w");
     if (!f) {
         int err = AVERROR(EINVAL);
         char buf[128];
@@ -500,7 +500,7 @@ static int binary_export(AVFilterContext *ctx, StreamContext *sc, const char* fi
     if (!buffer)
         return AVERROR(ENOMEM);
 
-    f = fopen(filename, "wb");
+    f = av_fopen_utf8(filename, "wb");
     if (!f) {
         int err = AVERROR(EINVAL);
         char buf[128];
diff --git a/libavfilter/vf_ssim.c b/libavfilter/vf_ssim.c
index 32f313817d..4a82cbec06 100644
--- a/libavfilter/vf_ssim.c
+++ b/libavfilter/vf_ssim.c
@@ -404,7 +404,7 @@ static av_cold int init(AVFilterContext *ctx)
         if (!strcmp(s->stats_file_str, "-")) {
             s->stats_file = stdout;
         } else {
-            s->stats_file = fopen(s->stats_file_str, "w");
+            s->stats_file = av_fopen_utf8(s->stats_file_str, "w");
             if (!s->stats_file) {
                 int err = AVERROR(errno);
                 char buf[128];
diff --git a/libavfilter/vf_vmafmotion.c b/libavfilter/vf_vmafmotion.c
index 8b7e9b17ef..2ac67e5935 100644
--- a/libavfilter/vf_vmafmotion.c
+++ b/libavfilter/vf_vmafmotion.c
@@ -312,7 +312,7 @@ static av_cold int init(AVFilterContext *ctx)
         if (!strcmp(s->stats_file_str, "-")) {
             s->stats_file = stdout;
         } else {
-            s->stats_file = fopen(s->stats_file_str, "w");
+            s->stats_file = av_fopen_utf8(s->stats_file_str, "w");
             if (!s->stats_file) {
                 int err = AVERROR(errno);
                 char buf[128];
-- 
ffmpeg-codebot
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [FFmpeg-devel] [PATCH 1/2] fftools: use av_fopen_utf8() instead of plain fopen()
  2022-05-07 17:39 ` [FFmpeg-devel] [PATCH 1/2] fftools: " softworkz
@ 2022-05-08 20:03   ` Martin Storsjö
  2022-05-09  0:21     ` Soft Works
  0 siblings, 1 reply; 30+ messages in thread
From: Martin Storsjö @ 2022-05-08 20:03 UTC (permalink / raw)
  To: FFmpeg development discussions and patches

On Sat, 7 May 2022, softworkz wrote:

> From: softworkz <softworkz@hotmail.com>
>
> Signed-off-by: softworkz <softworkz@hotmail.com>
> ---
> fftools/cmdutils.c   | 6 +++---
> fftools/ffmpeg.c     | 4 ++--
> fftools/opt_common.c | 2 +-
> 3 files changed, 6 insertions(+), 6 deletions(-)

Just for clarity (for someone looking at this individual mail thread on 
its own); please don't do this until the issue pointed out in 
https://ffmpeg.org/pipermail/ffmpeg-devel/2022-April/295488.html has been 
resolved.

// Martin

_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [FFmpeg-devel] [PATCH 1/2] fftools: use av_fopen_utf8() instead of plain fopen()
  2022-05-08 20:03   ` Martin Storsjö
@ 2022-05-09  0:21     ` Soft Works
  0 siblings, 0 replies; 30+ messages in thread
From: Soft Works @ 2022-05-09  0:21 UTC (permalink / raw)
  To: FFmpeg development discussions and patches



> -----Original Message-----
> From: ffmpeg-devel <ffmpeg-devel-bounces@ffmpeg.org> On Behalf Of
> Martin Storsjö
> Sent: Sunday, May 8, 2022 10:03 PM
> To: FFmpeg development discussions and patches <ffmpeg-
> devel@ffmpeg.org>
> Subject: Re: [FFmpeg-devel] [PATCH 1/2] fftools: use av_fopen_utf8()
> instead of plain fopen()
> 
> On Sat, 7 May 2022, softworkz wrote:
> 
> > From: softworkz <softworkz@hotmail.com>
> >
> > Signed-off-by: softworkz <softworkz@hotmail.com>
> > ---
> > fftools/cmdutils.c   | 6 +++---
> > fftools/ffmpeg.c     | 4 ++--
> > fftools/opt_common.c | 2 +-
> > 3 files changed, 6 insertions(+), 6 deletions(-)
> 
> Just for clarity (for someone looking at this individual mail thread
> on
> its own); please don't do this until the issue pointed out in
> https://ffmpeg.org/pipermail/ffmpeg-devel/2022-April/295488.html has
> been
> resolved.

I agree. I will retract this part of the patchset for now.

Thanks,
softworkz
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

^ permalink raw reply	[flat|nested] 30+ messages in thread

* [FFmpeg-devel] [PATCH v2] avfilter: use av_fopen_utf8() instead of plain fopen()
  2022-05-07 17:39 [FFmpeg-devel] [PATCH 0/2] use av_fopen_utf8() instead of plain fopen() ffmpegagent
  2022-05-07 17:39 ` [FFmpeg-devel] [PATCH 1/2] fftools: " softworkz
  2022-05-07 17:39 ` [FFmpeg-devel] [PATCH 2/2] avfilter: " softworkz
@ 2022-05-09 18:52 ` softworkz
  2022-05-10 20:12   ` Martin Storsjö
  2022-05-17  0:39   ` [FFmpeg-devel] [PATCH v3 0/2] " ffmpegagent
  2 siblings, 2 replies; 30+ messages in thread
From: softworkz @ 2022-05-09 18:52 UTC (permalink / raw)
  To: ffmpeg-devel; +Cc: Martin Storsjö, softworkz

From: softworkz <softworkz@hotmail.com>

Signed-off-by: softworkz <softworkz@hotmail.com>
---
    use av_fopen_utf8() instead of plain fopen()
    
    Unify file access operations by replacing usages of direct calls to
    posix fopen()
    
    v2: Remove changes to fftools for now

Published-As: https://github.com/ffstaging/FFmpeg/releases/tag/pr-ffstaging-26%2Fsoftworkz%2Fsubmit_replace_fopen-v2
Fetch-It-Via: git fetch https://github.com/ffstaging/FFmpeg pr-ffstaging-26/softworkz/submit_replace_fopen-v2
Pull-Request: https://github.com/ffstaging/FFmpeg/pull/26

Range-diff vs v1:

 1:  5802c8526c < -:  ---------- fftools: use av_fopen_utf8() instead of plain fopen()
 2:  3266640a93 = 1:  e47287be64 avfilter: use av_fopen_utf8() instead of plain fopen()


 libavfilter/af_firequalizer.c | 2 +-
 libavfilter/vf_deshake.c      | 2 +-
 libavfilter/vf_signature.c    | 4 ++--
 libavfilter/vf_ssim.c         | 2 +-
 libavfilter/vf_vmafmotion.c   | 2 +-
 5 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/libavfilter/af_firequalizer.c b/libavfilter/af_firequalizer.c
index c19a2fe122..e1497dcef0 100644
--- a/libavfilter/af_firequalizer.c
+++ b/libavfilter/af_firequalizer.c
@@ -604,7 +604,7 @@ static int generate_kernel(AVFilterContext *ctx, const char *gain, const char *g
     if (ret < 0)
         return ret;
 
-    if (s->dumpfile && (!s->dump_buf || !s->analysis_rdft || !(dump_fp = fopen(s->dumpfile, "w"))))
+    if (s->dumpfile && (!s->dump_buf || !s->analysis_rdft || !(dump_fp = av_fopen_utf8(s->dumpfile, "w"))))
         av_log(ctx, AV_LOG_WARNING, "dumping failed.\n");
 
     vars[VAR_CHS] = inlink->ch_layout.nb_channels;
diff --git a/libavfilter/vf_deshake.c b/libavfilter/vf_deshake.c
index 4f28467bb2..dea69e11cd 100644
--- a/libavfilter/vf_deshake.c
+++ b/libavfilter/vf_deshake.c
@@ -353,7 +353,7 @@ static av_cold int init(AVFilterContext *ctx)
     }
 
     if (deshake->filename)
-        deshake->fp = fopen(deshake->filename, "w");
+        deshake->fp = av_fopen_utf8(deshake->filename, "w");
     if (deshake->fp)
         fwrite("Ori x, Avg x, Fin x, Ori y, Avg y, Fin y, Ori angle, Avg angle, Fin angle, Ori zoom, Avg zoom, Fin zoom\n", 1, 104, deshake->fp);
 
diff --git a/libavfilter/vf_signature.c b/libavfilter/vf_signature.c
index 4ca57ebf1d..904123fd4e 100644
--- a/libavfilter/vf_signature.c
+++ b/libavfilter/vf_signature.c
@@ -386,7 +386,7 @@ static int xml_export(AVFilterContext *ctx, StreamContext *sc, const char* filen
     FILE* f;
     unsigned int pot3[5] = { 3*3*3*3, 3*3*3, 3*3, 3, 1 };
 
-    f = fopen(filename, "w");
+    f = av_fopen_utf8(filename, "w");
     if (!f) {
         int err = AVERROR(EINVAL);
         char buf[128];
@@ -500,7 +500,7 @@ static int binary_export(AVFilterContext *ctx, StreamContext *sc, const char* fi
     if (!buffer)
         return AVERROR(ENOMEM);
 
-    f = fopen(filename, "wb");
+    f = av_fopen_utf8(filename, "wb");
     if (!f) {
         int err = AVERROR(EINVAL);
         char buf[128];
diff --git a/libavfilter/vf_ssim.c b/libavfilter/vf_ssim.c
index 32f313817d..4a82cbec06 100644
--- a/libavfilter/vf_ssim.c
+++ b/libavfilter/vf_ssim.c
@@ -404,7 +404,7 @@ static av_cold int init(AVFilterContext *ctx)
         if (!strcmp(s->stats_file_str, "-")) {
             s->stats_file = stdout;
         } else {
-            s->stats_file = fopen(s->stats_file_str, "w");
+            s->stats_file = av_fopen_utf8(s->stats_file_str, "w");
             if (!s->stats_file) {
                 int err = AVERROR(errno);
                 char buf[128];
diff --git a/libavfilter/vf_vmafmotion.c b/libavfilter/vf_vmafmotion.c
index 8b7e9b17ef..2ac67e5935 100644
--- a/libavfilter/vf_vmafmotion.c
+++ b/libavfilter/vf_vmafmotion.c
@@ -312,7 +312,7 @@ static av_cold int init(AVFilterContext *ctx)
         if (!strcmp(s->stats_file_str, "-")) {
             s->stats_file = stdout;
         } else {
-            s->stats_file = fopen(s->stats_file_str, "w");
+            s->stats_file = av_fopen_utf8(s->stats_file_str, "w");
             if (!s->stats_file) {
                 int err = AVERROR(errno);
                 char buf[128];

base-commit: f3b7ba21ba49b32b4476a8c7c5a9bcdad15e3943
-- 
ffmpeg-codebot
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [FFmpeg-devel] [PATCH v2] avfilter: use av_fopen_utf8() instead of plain fopen()
  2022-05-09 18:52 ` [FFmpeg-devel] [PATCH v2] " softworkz
@ 2022-05-10 20:12   ` Martin Storsjö
  2022-05-10 23:03     ` Soft Works
  2022-05-17  0:39   ` [FFmpeg-devel] [PATCH v3 0/2] " ffmpegagent
  1 sibling, 1 reply; 30+ messages in thread
From: Martin Storsjö @ 2022-05-10 20:12 UTC (permalink / raw)
  To: softworkz; +Cc: Soft Works, ffmpeg-devel

On Mon, 9 May 2022, softworkz wrote:

> From: softworkz <softworkz@hotmail.com>
>
> Signed-off-by: softworkz <softworkz@hotmail.com>
> ---
>    use av_fopen_utf8() instead of plain fopen()
>
>    Unify file access operations by replacing usages of direct calls to
>    posix fopen()
>
>    v2: Remove changes to fftools for now
>
> Published-As: https://github.com/ffstaging/FFmpeg/releases/tag/pr-ffstaging-26%2Fsoftworkz%2Fsubmit_replace_fopen-v2
> Fetch-It-Via: git fetch https://github.com/ffstaging/FFmpeg pr-ffstaging-26/softworkz/submit_replace_fopen-v2
> Pull-Request: https://github.com/ffstaging/FFmpeg/pull/26
>
> Range-diff vs v1:
>
> 1:  5802c8526c < -:  ---------- fftools: use av_fopen_utf8() instead of plain fopen()
> 2:  3266640a93 = 1:  e47287be64 avfilter: use av_fopen_utf8() instead of plain fopen()
>
>
> libavfilter/af_firequalizer.c | 2 +-
> libavfilter/vf_deshake.c      | 2 +-
> libavfilter/vf_signature.c    | 4 ++--
> libavfilter/vf_ssim.c         | 2 +-
> libavfilter/vf_vmafmotion.c   | 2 +-
> 5 files changed, 6 insertions(+), 6 deletions(-)

LGTM I think. For fully fixing the situation about this function, I 
believe we're going to need to rename it (as the proper solution won't be 
a public function), but as there's already some uses, it's probably fine 
to first take it into use consistently, and then rename all the 
occurrances later.

But we should probably add a copy of file_open.o in libavfilter too (as 
you noted). This is indeed a preexisting problem, but the issue will 
become more visible if we use it in more places.

// Martin

_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [FFmpeg-devel] [PATCH v2] avfilter: use av_fopen_utf8() instead of plain fopen()
  2022-05-10 20:12   ` Martin Storsjö
@ 2022-05-10 23:03     ` Soft Works
  0 siblings, 0 replies; 30+ messages in thread
From: Soft Works @ 2022-05-10 23:03 UTC (permalink / raw)
  To: Martin Storsjö, softworkz; +Cc: ffmpeg-devel



> -----Original Message-----
> From: Martin Storsjö <martin@martin.st>
> Sent: Tuesday, May 10, 2022 10:12 PM
> To: softworkz <ffmpegagent@gmail.com>
> Cc: ffmpeg-devel@ffmpeg.org; Soft Works <softworkz@hotmail.com>
> Subject: Re: [PATCH v2] avfilter: use av_fopen_utf8() instead of plain
> fopen()
> 
> On Mon, 9 May 2022, softworkz wrote:
> 
> > From: softworkz <softworkz@hotmail.com>
> >
> > Signed-off-by: softworkz <softworkz@hotmail.com>
> > ---
> >    use av_fopen_utf8() instead of plain fopen()
> >
> >    Unify file access operations by replacing usages of direct calls
> to
> >    posix fopen()
> >
> >    v2: Remove changes to fftools for now
> >
> > Published-As: https://github.com/ffstaging/FFmpeg/releases/tag/pr-
> ffstaging-26%2Fsoftworkz%2Fsubmit_replace_fopen-v2
> > Fetch-It-Via: git fetch https://github.com/ffstaging/FFmpeg pr-
> ffstaging-26/softworkz/submit_replace_fopen-v2
> > Pull-Request: https://github.com/ffstaging/FFmpeg/pull/26
> >
> > Range-diff vs v1:
> >
> > 1:  5802c8526c < -:  ---------- fftools: use av_fopen_utf8() instead
> of plain fopen()
> > 2:  3266640a93 = 1:  e47287be64 avfilter: use av_fopen_utf8()
> instead of plain fopen()
> >
> >
> > libavfilter/af_firequalizer.c | 2 +-
> > libavfilter/vf_deshake.c      | 2 +-
> > libavfilter/vf_signature.c    | 4 ++--
> > libavfilter/vf_ssim.c         | 2 +-
> > libavfilter/vf_vmafmotion.c   | 2 +-
> > 5 files changed, 6 insertions(+), 6 deletions(-)
> 
> LGTM I think. For fully fixing the situation about this function, I
> believe we're going to need to rename it (as the proper solution won't
> be
> a public function), but as there's already some uses, it's probably
> fine
> to first take it into use consistently, and then rename all the
> occurrances later.

Makes sense. Thanks for reviewing.

> But we should probably add a copy of file_open.o in libavfilter too
> (as
> you noted). This is indeed a preexisting problem, but the issue will
> become more visible if we use it in more places.

Would you able to submit a patch for this or shall I?
(I'd prefer the former ;-)

Thanks,
softworkz
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

^ permalink raw reply	[flat|nested] 30+ messages in thread

* [FFmpeg-devel] [PATCH v3 0/2] use av_fopen_utf8() instead of plain fopen()
  2022-05-09 18:52 ` [FFmpeg-devel] [PATCH v2] " softworkz
  2022-05-10 20:12   ` Martin Storsjö
@ 2022-05-17  0:39   ` ffmpegagent
  2022-05-17  0:39     ` [FFmpeg-devel] [PATCH v3 1/2] avfilter: " softworkz
                       ` (3 more replies)
  1 sibling, 4 replies; 30+ messages in thread
From: ffmpegagent @ 2022-05-17  0:39 UTC (permalink / raw)
  To: ffmpeg-devel; +Cc: Martin Storsjö, softworkz

Unify file access operations by replacing usages of direct calls to posix
fopen()

v2: Remove changes to fftools for now
v3: Add some additional replacements

softworkz (2):
  avfilter: use av_fopen_utf8() instead of plain fopen()
  avfilter/dvdsubdec: use av_fopen_utf8() instead of plain fopen()

 libavcodec/dvdsubdec.c            | 2 +-
 libavfilter/af_firequalizer.c     | 2 +-
 libavfilter/vf_deshake.c          | 2 +-
 libavfilter/vf_psnr.c             | 2 +-
 libavfilter/vf_signature.c        | 4 ++--
 libavfilter/vf_ssim.c             | 2 +-
 libavfilter/vf_vidstabdetect.c    | 2 +-
 libavfilter/vf_vidstabtransform.c | 2 +-
 libavfilter/vf_vmafmotion.c       | 2 +-
 9 files changed, 10 insertions(+), 10 deletions(-)


base-commit: e3580f60775c897c3b13b178c57ab191ecc4a031
Published-As: https://github.com/ffstaging/FFmpeg/releases/tag/pr-ffstaging-26%2Fsoftworkz%2Fsubmit_replace_fopen-v3
Fetch-It-Via: git fetch https://github.com/ffstaging/FFmpeg pr-ffstaging-26/softworkz/submit_replace_fopen-v3
Pull-Request: https://github.com/ffstaging/FFmpeg/pull/26

Range-diff vs v2:

 1:  e47287be64 ! 1:  d81855ba42 avfilter: use av_fopen_utf8() instead of plain fopen()
     @@ libavfilter/vf_deshake.c: static av_cold int init(AVFilterContext *ctx)
               fwrite("Ori x, Avg x, Fin x, Ori y, Avg y, Fin y, Ori angle, Avg angle, Fin angle, Ori zoom, Avg zoom, Fin zoom\n", 1, 104, deshake->fp);
       
      
     + ## libavfilter/vf_psnr.c ##
     +@@ libavfilter/vf_psnr.c: static av_cold int init(AVFilterContext *ctx)
     +         if (!strcmp(s->stats_file_str, "-")) {
     +             s->stats_file = stdout;
     +         } else {
     +-            s->stats_file = fopen(s->stats_file_str, "w");
     ++            s->stats_file = av_fopen_utf8(s->stats_file_str, "w");
     +             if (!s->stats_file) {
     +                 int err = AVERROR(errno);
     +                 char buf[128];
     +
       ## libavfilter/vf_signature.c ##
      @@ libavfilter/vf_signature.c: static int xml_export(AVFilterContext *ctx, StreamContext *sc, const char* filen
           FILE* f;
     @@ libavfilter/vf_ssim.c: static av_cold int init(AVFilterContext *ctx)
                       int err = AVERROR(errno);
                       char buf[128];
      
     + ## libavfilter/vf_vidstabdetect.c ##
     +@@ libavfilter/vf_vidstabdetect.c: static int config_input(AVFilterLink *inlink)
     +     av_log(ctx, AV_LOG_INFO, "          show = %d\n", s->conf.show);
     +     av_log(ctx, AV_LOG_INFO, "        result = %s\n", s->result);
     + 
     +-    s->f = fopen(s->result, "w");
     ++    s->f = av_fopen_utf8(s->result, "w");
     +     if (s->f == NULL) {
     +         av_log(ctx, AV_LOG_ERROR, "cannot open transform file %s\n", s->result);
     +         return AVERROR(EINVAL);
     +
     + ## libavfilter/vf_vidstabtransform.c ##
     +@@ libavfilter/vf_vidstabtransform.c: static int config_input(AVFilterLink *inlink)
     +         av_log(ctx, AV_LOG_INFO, "    zoomspeed = %g\n", tc->conf.zoomSpeed);
     +     av_log(ctx, AV_LOG_INFO, "    interpol  = %s\n", getInterpolationTypeName(tc->conf.interpolType));
     + 
     +-    f = fopen(tc->input, "r");
     ++    f = av_fopen_utf8(tc->input, "r");
     +     if (!f) {
     +         int ret = AVERROR(errno);
     +         av_log(ctx, AV_LOG_ERROR, "cannot open input file %s\n", tc->input);
     +
       ## libavfilter/vf_vmafmotion.c ##
      @@ libavfilter/vf_vmafmotion.c: static av_cold int init(AVFilterContext *ctx)
               if (!strcmp(s->stats_file_str, "-")) {
 -:  ---------- > 2:  1be02d9e04 avfilter/dvdsubdec: use av_fopen_utf8() instead of plain fopen()

-- 
ffmpeg-codebot
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

^ permalink raw reply	[flat|nested] 30+ messages in thread

* [FFmpeg-devel] [PATCH v3 1/2] avfilter: use av_fopen_utf8() instead of plain fopen()
  2022-05-17  0:39   ` [FFmpeg-devel] [PATCH v3 0/2] " ffmpegagent
@ 2022-05-17  0:39     ` softworkz
  2022-05-17  0:39     ` [FFmpeg-devel] [PATCH v3 2/2] avfilter/dvdsubdec: " softworkz
                       ` (2 subsequent siblings)
  3 siblings, 0 replies; 30+ messages in thread
From: softworkz @ 2022-05-17  0:39 UTC (permalink / raw)
  To: ffmpeg-devel; +Cc: Martin Storsjö, softworkz

From: softworkz <softworkz@hotmail.com>

Signed-off-by: softworkz <softworkz@hotmail.com>
---
 libavfilter/af_firequalizer.c     | 2 +-
 libavfilter/vf_deshake.c          | 2 +-
 libavfilter/vf_psnr.c             | 2 +-
 libavfilter/vf_signature.c        | 4 ++--
 libavfilter/vf_ssim.c             | 2 +-
 libavfilter/vf_vidstabdetect.c    | 2 +-
 libavfilter/vf_vidstabtransform.c | 2 +-
 libavfilter/vf_vmafmotion.c       | 2 +-
 8 files changed, 9 insertions(+), 9 deletions(-)

diff --git a/libavfilter/af_firequalizer.c b/libavfilter/af_firequalizer.c
index c19a2fe122..e1497dcef0 100644
--- a/libavfilter/af_firequalizer.c
+++ b/libavfilter/af_firequalizer.c
@@ -604,7 +604,7 @@ static int generate_kernel(AVFilterContext *ctx, const char *gain, const char *g
     if (ret < 0)
         return ret;
 
-    if (s->dumpfile && (!s->dump_buf || !s->analysis_rdft || !(dump_fp = fopen(s->dumpfile, "w"))))
+    if (s->dumpfile && (!s->dump_buf || !s->analysis_rdft || !(dump_fp = av_fopen_utf8(s->dumpfile, "w"))))
         av_log(ctx, AV_LOG_WARNING, "dumping failed.\n");
 
     vars[VAR_CHS] = inlink->ch_layout.nb_channels;
diff --git a/libavfilter/vf_deshake.c b/libavfilter/vf_deshake.c
index 4f28467bb2..dea69e11cd 100644
--- a/libavfilter/vf_deshake.c
+++ b/libavfilter/vf_deshake.c
@@ -353,7 +353,7 @@ static av_cold int init(AVFilterContext *ctx)
     }
 
     if (deshake->filename)
-        deshake->fp = fopen(deshake->filename, "w");
+        deshake->fp = av_fopen_utf8(deshake->filename, "w");
     if (deshake->fp)
         fwrite("Ori x, Avg x, Fin x, Ori y, Avg y, Fin y, Ori angle, Avg angle, Fin angle, Ori zoom, Avg zoom, Fin zoom\n", 1, 104, deshake->fp);
 
diff --git a/libavfilter/vf_psnr.c b/libavfilter/vf_psnr.c
index 19852eaa69..09c2a5164a 100644
--- a/libavfilter/vf_psnr.c
+++ b/libavfilter/vf_psnr.c
@@ -280,7 +280,7 @@ static av_cold int init(AVFilterContext *ctx)
         if (!strcmp(s->stats_file_str, "-")) {
             s->stats_file = stdout;
         } else {
-            s->stats_file = fopen(s->stats_file_str, "w");
+            s->stats_file = av_fopen_utf8(s->stats_file_str, "w");
             if (!s->stats_file) {
                 int err = AVERROR(errno);
                 char buf[128];
diff --git a/libavfilter/vf_signature.c b/libavfilter/vf_signature.c
index 4ca57ebf1d..904123fd4e 100644
--- a/libavfilter/vf_signature.c
+++ b/libavfilter/vf_signature.c
@@ -386,7 +386,7 @@ static int xml_export(AVFilterContext *ctx, StreamContext *sc, const char* filen
     FILE* f;
     unsigned int pot3[5] = { 3*3*3*3, 3*3*3, 3*3, 3, 1 };
 
-    f = fopen(filename, "w");
+    f = av_fopen_utf8(filename, "w");
     if (!f) {
         int err = AVERROR(EINVAL);
         char buf[128];
@@ -500,7 +500,7 @@ static int binary_export(AVFilterContext *ctx, StreamContext *sc, const char* fi
     if (!buffer)
         return AVERROR(ENOMEM);
 
-    f = fopen(filename, "wb");
+    f = av_fopen_utf8(filename, "wb");
     if (!f) {
         int err = AVERROR(EINVAL);
         char buf[128];
diff --git a/libavfilter/vf_ssim.c b/libavfilter/vf_ssim.c
index 32f313817d..4a82cbec06 100644
--- a/libavfilter/vf_ssim.c
+++ b/libavfilter/vf_ssim.c
@@ -404,7 +404,7 @@ static av_cold int init(AVFilterContext *ctx)
         if (!strcmp(s->stats_file_str, "-")) {
             s->stats_file = stdout;
         } else {
-            s->stats_file = fopen(s->stats_file_str, "w");
+            s->stats_file = av_fopen_utf8(s->stats_file_str, "w");
             if (!s->stats_file) {
                 int err = AVERROR(errno);
                 char buf[128];
diff --git a/libavfilter/vf_vidstabdetect.c b/libavfilter/vf_vidstabdetect.c
index 267a62ea9b..4acae5a3ea 100644
--- a/libavfilter/vf_vidstabdetect.c
+++ b/libavfilter/vf_vidstabdetect.c
@@ -126,7 +126,7 @@ static int config_input(AVFilterLink *inlink)
     av_log(ctx, AV_LOG_INFO, "          show = %d\n", s->conf.show);
     av_log(ctx, AV_LOG_INFO, "        result = %s\n", s->result);
 
-    s->f = fopen(s->result, "w");
+    s->f = av_fopen_utf8(s->result, "w");
     if (s->f == NULL) {
         av_log(ctx, AV_LOG_ERROR, "cannot open transform file %s\n", s->result);
         return AVERROR(EINVAL);
diff --git a/libavfilter/vf_vidstabtransform.c b/libavfilter/vf_vidstabtransform.c
index 4619e9b256..17214f039f 100644
--- a/libavfilter/vf_vidstabtransform.c
+++ b/libavfilter/vf_vidstabtransform.c
@@ -191,7 +191,7 @@ static int config_input(AVFilterLink *inlink)
         av_log(ctx, AV_LOG_INFO, "    zoomspeed = %g\n", tc->conf.zoomSpeed);
     av_log(ctx, AV_LOG_INFO, "    interpol  = %s\n", getInterpolationTypeName(tc->conf.interpolType));
 
-    f = fopen(tc->input, "r");
+    f = av_fopen_utf8(tc->input, "r");
     if (!f) {
         int ret = AVERROR(errno);
         av_log(ctx, AV_LOG_ERROR, "cannot open input file %s\n", tc->input);
diff --git a/libavfilter/vf_vmafmotion.c b/libavfilter/vf_vmafmotion.c
index 8b7e9b17ef..2ac67e5935 100644
--- a/libavfilter/vf_vmafmotion.c
+++ b/libavfilter/vf_vmafmotion.c
@@ -312,7 +312,7 @@ static av_cold int init(AVFilterContext *ctx)
         if (!strcmp(s->stats_file_str, "-")) {
             s->stats_file = stdout;
         } else {
-            s->stats_file = fopen(s->stats_file_str, "w");
+            s->stats_file = av_fopen_utf8(s->stats_file_str, "w");
             if (!s->stats_file) {
                 int err = AVERROR(errno);
                 char buf[128];
-- 
ffmpeg-codebot

_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

^ permalink raw reply	[flat|nested] 30+ messages in thread

* [FFmpeg-devel] [PATCH v3 2/2] avfilter/dvdsubdec: use av_fopen_utf8() instead of plain fopen()
  2022-05-17  0:39   ` [FFmpeg-devel] [PATCH v3 0/2] " ffmpegagent
  2022-05-17  0:39     ` [FFmpeg-devel] [PATCH v3 1/2] avfilter: " softworkz
@ 2022-05-17  0:39     ` softworkz
  2022-05-17 11:56     ` [FFmpeg-devel] [PATCH v3 0/2] " Tobias Rapp
  2022-05-17 12:29     ` [FFmpeg-devel] [PATCH v4 " ffmpegagent
  3 siblings, 0 replies; 30+ messages in thread
From: softworkz @ 2022-05-17  0:39 UTC (permalink / raw)
  To: ffmpeg-devel; +Cc: Martin Storsjö, softworkz

From: softworkz <softworkz@hotmail.com>

Signed-off-by: softworkz <softworkz@hotmail.com>
---
 libavcodec/dvdsubdec.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavcodec/dvdsubdec.c b/libavcodec/dvdsubdec.c
index 30fe4d41de..19b78b3eb1 100644
--- a/libavcodec/dvdsubdec.c
+++ b/libavcodec/dvdsubdec.c
@@ -617,7 +617,7 @@ static int parse_ifo_palette(DVDSubContext *ctx, char *p)
     const uint8_t *cm = ff_crop_tab + MAX_NEG_CROP;
 
     ctx->has_palette = 0;
-    if ((ifo = fopen(p, "r")) == NULL) {
+    if ((ifo = av_fopen_utf8(p, "r")) == NULL) {
         av_log(ctx, AV_LOG_WARNING, "Unable to open IFO file \"%s\": %s\n", p, av_err2str(AVERROR(errno)));
         return AVERROR_EOF;
     }
-- 
ffmpeg-codebot
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [FFmpeg-devel] [PATCH v3 0/2] use av_fopen_utf8() instead of plain fopen()
  2022-05-17  0:39   ` [FFmpeg-devel] [PATCH v3 0/2] " ffmpegagent
  2022-05-17  0:39     ` [FFmpeg-devel] [PATCH v3 1/2] avfilter: " softworkz
  2022-05-17  0:39     ` [FFmpeg-devel] [PATCH v3 2/2] avfilter/dvdsubdec: " softworkz
@ 2022-05-17 11:56     ` Tobias Rapp
  2022-05-17 12:26       ` Soft Works
  2022-05-17 12:29     ` [FFmpeg-devel] [PATCH v4 " ffmpegagent
  3 siblings, 1 reply; 30+ messages in thread
From: Tobias Rapp @ 2022-05-17 11:56 UTC (permalink / raw)
  To: FFmpeg development discussions and patches, ffmpegagent
  Cc: Martin Storsjö, softworkz

On 17/05/2022 02:39, ffmpegagent wrote:
> Unify file access operations by replacing usages of direct calls to posix
> fopen()

As the cover letter will be gone after commit I think it would be a good 
idea to add the reason for the change also in the commit messages directly.

Is this in preparation for the long filename support on Windows? Then 
maybe this could be mentioned, too.

> v2: Remove changes to fftools for now
> v3: Add some additional replacements
> 
> softworkz (2):
>    avfilter: use av_fopen_utf8() instead of plain fopen()
>    avfilter/dvdsubdec: use av_fopen_utf8() instead of plain fopen()

Patch #2 title should start with "avcodec/dvdsubdec: ..." I guess.

> 
>   libavcodec/dvdsubdec.c            | 2 +-
>   libavfilter/af_firequalizer.c     | 2 +-
>   libavfilter/vf_deshake.c          | 2 +-
>   libavfilter/vf_psnr.c             | 2 +-
>   libavfilter/vf_signature.c        | 4 ++--
>   libavfilter/vf_ssim.c             | 2 +-
>   libavfilter/vf_vidstabdetect.c    | 2 +-
>   libavfilter/vf_vidstabtransform.c | 2 +-
>   libavfilter/vf_vmafmotion.c       | 2 +-
>   9 files changed, 10 insertions(+), 10 deletions(-)
> 
> [...]

Regards,
Tobias

_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [FFmpeg-devel] [PATCH v3 0/2] use av_fopen_utf8() instead of plain fopen()
  2022-05-17 11:56     ` [FFmpeg-devel] [PATCH v3 0/2] " Tobias Rapp
@ 2022-05-17 12:26       ` Soft Works
  0 siblings, 0 replies; 30+ messages in thread
From: Soft Works @ 2022-05-17 12:26 UTC (permalink / raw)
  To: Tobias Rapp, FFmpeg development discussions and patches, ffmpegagent
  Cc: Martin Storsjö



> -----Original Message-----
> From: Tobias Rapp <t.rapp@noa-archive.com>
> Sent: Tuesday, May 17, 2022 1:56 PM
> To: FFmpeg development discussions and patches <ffmpeg-
> devel@ffmpeg.org>; ffmpegagent <ffmpegagent@gmail.com>
> Cc: Martin Storsjö <martin@martin.st>; softworkz
> <softworkz@hotmail.com>
> Subject: Re: [FFmpeg-devel] [PATCH v3 0/2] use av_fopen_utf8() instead
> of plain fopen()
> 
> On 17/05/2022 02:39, ffmpegagent wrote:
> > Unify file access operations by replacing usages of direct calls to
> posix
> > fopen()
> 
> As the cover letter will be gone after commit I think it would be a
> good
> idea to add the reason for the change also in the commit messages
> directly.
> 
> Is this in preparation for the long filename support on Windows? Then
> maybe this could be mentioned, too.
> 
> > v2: Remove changes to fftools for now
> > v3: Add some additional replacements
> >
> > softworkz (2):
> >    avfilter: use av_fopen_utf8() instead of plain fopen()
> >    avfilter/dvdsubdec: use av_fopen_utf8() instead of plain fopen()
> 
> Patch #2 title should start with "avcodec/dvdsubdec: ..." I guess.

Yes, yes and yes. ;-)

Thanks a lot for reviewing. Update will follow.

Kind regards,
softworkz
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

^ permalink raw reply	[flat|nested] 30+ messages in thread

* [FFmpeg-devel] [PATCH v4 0/2] use av_fopen_utf8() instead of plain fopen()
  2022-05-17  0:39   ` [FFmpeg-devel] [PATCH v3 0/2] " ffmpegagent
                       ` (2 preceding siblings ...)
  2022-05-17 11:56     ` [FFmpeg-devel] [PATCH v3 0/2] " Tobias Rapp
@ 2022-05-17 12:29     ` ffmpegagent
  2022-05-17 12:29       ` [FFmpeg-devel] [PATCH v4 1/2] avfilter: " softworkz
                         ` (3 more replies)
  3 siblings, 4 replies; 30+ messages in thread
From: ffmpegagent @ 2022-05-17 12:29 UTC (permalink / raw)
  To: ffmpeg-devel; +Cc: Martin Storsjö, softworkz, Tobias Rapp

Unify file access operations by replacing usages of direct calls to posix
fopen()

v2: Remove changes to fftools for now
v3: Add some additional replacements
v4: Fix and improve commit messages

softworkz (2):
  avfilter: use av_fopen_utf8() instead of plain fopen()
  avcodec/dvdsubdec: use av_fopen_utf8() instead of plain fopen()

 libavcodec/dvdsubdec.c            | 2 +-
 libavfilter/af_firequalizer.c     | 2 +-
 libavfilter/vf_deshake.c          | 2 +-
 libavfilter/vf_psnr.c             | 2 +-
 libavfilter/vf_signature.c        | 4 ++--
 libavfilter/vf_ssim.c             | 2 +-
 libavfilter/vf_vidstabdetect.c    | 2 +-
 libavfilter/vf_vidstabtransform.c | 2 +-
 libavfilter/vf_vmafmotion.c       | 2 +-
 9 files changed, 10 insertions(+), 10 deletions(-)


base-commit: e3580f60775c897c3b13b178c57ab191ecc4a031
Published-As: https://github.com/ffstaging/FFmpeg/releases/tag/pr-ffstaging-26%2Fsoftworkz%2Fsubmit_replace_fopen-v4
Fetch-It-Via: git fetch https://github.com/ffstaging/FFmpeg pr-ffstaging-26/softworkz/submit_replace_fopen-v4
Pull-Request: https://github.com/ffstaging/FFmpeg/pull/26

Range-diff vs v3:

 1:  d81855ba42 ! 1:  7c455d7fa0 avfilter: use av_fopen_utf8() instead of plain fopen()
     @@ Metadata
       ## Commit message ##
          avfilter: use av_fopen_utf8() instead of plain fopen()
      
     +    Unify file access operations by replacing usages of direct calls
     +    to posix fopen() to prepare for long filename support on Windows.
     +
          Signed-off-by: softworkz <softworkz@hotmail.com>
      
       ## libavfilter/af_firequalizer.c ##
 2:  1be02d9e04 ! 2:  68192b1a1e avfilter/dvdsubdec: use av_fopen_utf8() instead of plain fopen()
     @@ Metadata
      Author: softworkz <softworkz@hotmail.com>
      
       ## Commit message ##
     -    avfilter/dvdsubdec: use av_fopen_utf8() instead of plain fopen()
     +    avcodec/dvdsubdec: use av_fopen_utf8() instead of plain fopen()
     +
     +    Unify file access operations by replacing usages of direct calls
     +    to posix fopen() to prepare for long filename support on Windows.
      
          Signed-off-by: softworkz <softworkz@hotmail.com>
      

-- 
ffmpeg-codebot
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

^ permalink raw reply	[flat|nested] 30+ messages in thread

* [FFmpeg-devel] [PATCH v4 1/2] avfilter: use av_fopen_utf8() instead of plain fopen()
  2022-05-17 12:29     ` [FFmpeg-devel] [PATCH v4 " ffmpegagent
@ 2022-05-17 12:29       ` softworkz
  2022-05-17 12:29       ` [FFmpeg-devel] [PATCH v4 2/2] avcodec/dvdsubdec: " softworkz
                         ` (2 subsequent siblings)
  3 siblings, 0 replies; 30+ messages in thread
From: softworkz @ 2022-05-17 12:29 UTC (permalink / raw)
  To: ffmpeg-devel; +Cc: Martin Storsjö, softworkz, Tobias Rapp

From: softworkz <softworkz@hotmail.com>

Unify file access operations by replacing usages of direct calls
to posix fopen() to prepare for long filename support on Windows.

Signed-off-by: softworkz <softworkz@hotmail.com>
---
 libavfilter/af_firequalizer.c     | 2 +-
 libavfilter/vf_deshake.c          | 2 +-
 libavfilter/vf_psnr.c             | 2 +-
 libavfilter/vf_signature.c        | 4 ++--
 libavfilter/vf_ssim.c             | 2 +-
 libavfilter/vf_vidstabdetect.c    | 2 +-
 libavfilter/vf_vidstabtransform.c | 2 +-
 libavfilter/vf_vmafmotion.c       | 2 +-
 8 files changed, 9 insertions(+), 9 deletions(-)

diff --git a/libavfilter/af_firequalizer.c b/libavfilter/af_firequalizer.c
index c19a2fe122..e1497dcef0 100644
--- a/libavfilter/af_firequalizer.c
+++ b/libavfilter/af_firequalizer.c
@@ -604,7 +604,7 @@ static int generate_kernel(AVFilterContext *ctx, const char *gain, const char *g
     if (ret < 0)
         return ret;
 
-    if (s->dumpfile && (!s->dump_buf || !s->analysis_rdft || !(dump_fp = fopen(s->dumpfile, "w"))))
+    if (s->dumpfile && (!s->dump_buf || !s->analysis_rdft || !(dump_fp = av_fopen_utf8(s->dumpfile, "w"))))
         av_log(ctx, AV_LOG_WARNING, "dumping failed.\n");
 
     vars[VAR_CHS] = inlink->ch_layout.nb_channels;
diff --git a/libavfilter/vf_deshake.c b/libavfilter/vf_deshake.c
index 4f28467bb2..dea69e11cd 100644
--- a/libavfilter/vf_deshake.c
+++ b/libavfilter/vf_deshake.c
@@ -353,7 +353,7 @@ static av_cold int init(AVFilterContext *ctx)
     }
 
     if (deshake->filename)
-        deshake->fp = fopen(deshake->filename, "w");
+        deshake->fp = av_fopen_utf8(deshake->filename, "w");
     if (deshake->fp)
         fwrite("Ori x, Avg x, Fin x, Ori y, Avg y, Fin y, Ori angle, Avg angle, Fin angle, Ori zoom, Avg zoom, Fin zoom\n", 1, 104, deshake->fp);
 
diff --git a/libavfilter/vf_psnr.c b/libavfilter/vf_psnr.c
index 19852eaa69..09c2a5164a 100644
--- a/libavfilter/vf_psnr.c
+++ b/libavfilter/vf_psnr.c
@@ -280,7 +280,7 @@ static av_cold int init(AVFilterContext *ctx)
         if (!strcmp(s->stats_file_str, "-")) {
             s->stats_file = stdout;
         } else {
-            s->stats_file = fopen(s->stats_file_str, "w");
+            s->stats_file = av_fopen_utf8(s->stats_file_str, "w");
             if (!s->stats_file) {
                 int err = AVERROR(errno);
                 char buf[128];
diff --git a/libavfilter/vf_signature.c b/libavfilter/vf_signature.c
index 4ca57ebf1d..904123fd4e 100644
--- a/libavfilter/vf_signature.c
+++ b/libavfilter/vf_signature.c
@@ -386,7 +386,7 @@ static int xml_export(AVFilterContext *ctx, StreamContext *sc, const char* filen
     FILE* f;
     unsigned int pot3[5] = { 3*3*3*3, 3*3*3, 3*3, 3, 1 };
 
-    f = fopen(filename, "w");
+    f = av_fopen_utf8(filename, "w");
     if (!f) {
         int err = AVERROR(EINVAL);
         char buf[128];
@@ -500,7 +500,7 @@ static int binary_export(AVFilterContext *ctx, StreamContext *sc, const char* fi
     if (!buffer)
         return AVERROR(ENOMEM);
 
-    f = fopen(filename, "wb");
+    f = av_fopen_utf8(filename, "wb");
     if (!f) {
         int err = AVERROR(EINVAL);
         char buf[128];
diff --git a/libavfilter/vf_ssim.c b/libavfilter/vf_ssim.c
index 32f313817d..4a82cbec06 100644
--- a/libavfilter/vf_ssim.c
+++ b/libavfilter/vf_ssim.c
@@ -404,7 +404,7 @@ static av_cold int init(AVFilterContext *ctx)
         if (!strcmp(s->stats_file_str, "-")) {
             s->stats_file = stdout;
         } else {
-            s->stats_file = fopen(s->stats_file_str, "w");
+            s->stats_file = av_fopen_utf8(s->stats_file_str, "w");
             if (!s->stats_file) {
                 int err = AVERROR(errno);
                 char buf[128];
diff --git a/libavfilter/vf_vidstabdetect.c b/libavfilter/vf_vidstabdetect.c
index 267a62ea9b..4acae5a3ea 100644
--- a/libavfilter/vf_vidstabdetect.c
+++ b/libavfilter/vf_vidstabdetect.c
@@ -126,7 +126,7 @@ static int config_input(AVFilterLink *inlink)
     av_log(ctx, AV_LOG_INFO, "          show = %d\n", s->conf.show);
     av_log(ctx, AV_LOG_INFO, "        result = %s\n", s->result);
 
-    s->f = fopen(s->result, "w");
+    s->f = av_fopen_utf8(s->result, "w");
     if (s->f == NULL) {
         av_log(ctx, AV_LOG_ERROR, "cannot open transform file %s\n", s->result);
         return AVERROR(EINVAL);
diff --git a/libavfilter/vf_vidstabtransform.c b/libavfilter/vf_vidstabtransform.c
index 4619e9b256..17214f039f 100644
--- a/libavfilter/vf_vidstabtransform.c
+++ b/libavfilter/vf_vidstabtransform.c
@@ -191,7 +191,7 @@ static int config_input(AVFilterLink *inlink)
         av_log(ctx, AV_LOG_INFO, "    zoomspeed = %g\n", tc->conf.zoomSpeed);
     av_log(ctx, AV_LOG_INFO, "    interpol  = %s\n", getInterpolationTypeName(tc->conf.interpolType));
 
-    f = fopen(tc->input, "r");
+    f = av_fopen_utf8(tc->input, "r");
     if (!f) {
         int ret = AVERROR(errno);
         av_log(ctx, AV_LOG_ERROR, "cannot open input file %s\n", tc->input);
diff --git a/libavfilter/vf_vmafmotion.c b/libavfilter/vf_vmafmotion.c
index 8b7e9b17ef..2ac67e5935 100644
--- a/libavfilter/vf_vmafmotion.c
+++ b/libavfilter/vf_vmafmotion.c
@@ -312,7 +312,7 @@ static av_cold int init(AVFilterContext *ctx)
         if (!strcmp(s->stats_file_str, "-")) {
             s->stats_file = stdout;
         } else {
-            s->stats_file = fopen(s->stats_file_str, "w");
+            s->stats_file = av_fopen_utf8(s->stats_file_str, "w");
             if (!s->stats_file) {
                 int err = AVERROR(errno);
                 char buf[128];
-- 
ffmpeg-codebot

_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

^ permalink raw reply	[flat|nested] 30+ messages in thread

* [FFmpeg-devel] [PATCH v4 2/2] avcodec/dvdsubdec: use av_fopen_utf8() instead of plain fopen()
  2022-05-17 12:29     ` [FFmpeg-devel] [PATCH v4 " ffmpegagent
  2022-05-17 12:29       ` [FFmpeg-devel] [PATCH v4 1/2] avfilter: " softworkz
@ 2022-05-17 12:29       ` softworkz
  2022-05-18  7:01       ` [FFmpeg-devel] [PATCH v4 0/2] " Tobias Rapp
  2022-05-19 21:40       ` [FFmpeg-devel] [PATCH v5 0/3] " ffmpegagent
  3 siblings, 0 replies; 30+ messages in thread
From: softworkz @ 2022-05-17 12:29 UTC (permalink / raw)
  To: ffmpeg-devel; +Cc: Martin Storsjö, softworkz, Tobias Rapp

From: softworkz <softworkz@hotmail.com>

Unify file access operations by replacing usages of direct calls
to posix fopen() to prepare for long filename support on Windows.

Signed-off-by: softworkz <softworkz@hotmail.com>
---
 libavcodec/dvdsubdec.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavcodec/dvdsubdec.c b/libavcodec/dvdsubdec.c
index 30fe4d41de..19b78b3eb1 100644
--- a/libavcodec/dvdsubdec.c
+++ b/libavcodec/dvdsubdec.c
@@ -617,7 +617,7 @@ static int parse_ifo_palette(DVDSubContext *ctx, char *p)
     const uint8_t *cm = ff_crop_tab + MAX_NEG_CROP;
 
     ctx->has_palette = 0;
-    if ((ifo = fopen(p, "r")) == NULL) {
+    if ((ifo = av_fopen_utf8(p, "r")) == NULL) {
         av_log(ctx, AV_LOG_WARNING, "Unable to open IFO file \"%s\": %s\n", p, av_err2str(AVERROR(errno)));
         return AVERROR_EOF;
     }
-- 
ffmpeg-codebot
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [FFmpeg-devel] [PATCH v4 0/2] use av_fopen_utf8() instead of plain fopen()
  2022-05-17 12:29     ` [FFmpeg-devel] [PATCH v4 " ffmpegagent
  2022-05-17 12:29       ` [FFmpeg-devel] [PATCH v4 1/2] avfilter: " softworkz
  2022-05-17 12:29       ` [FFmpeg-devel] [PATCH v4 2/2] avcodec/dvdsubdec: " softworkz
@ 2022-05-18  7:01       ` Tobias Rapp
  2022-05-19 21:39         ` Soft Works
  2022-05-19 21:40       ` [FFmpeg-devel] [PATCH v5 0/3] " ffmpegagent
  3 siblings, 1 reply; 30+ messages in thread
From: Tobias Rapp @ 2022-05-18  7:01 UTC (permalink / raw)
  To: ffmpegagent, ffmpeg-devel; +Cc: Martin Storsjö, Soft Works

On 17/05/2022 14:29, ffmpegagent wrote:
> Unify file access operations by replacing usages of direct calls to posix
> fopen()
> 
> v2: Remove changes to fftools for now
> v3: Add some additional replacements
> v4: Fix and improve commit messages
> 
> softworkz (2):
>    avfilter: use av_fopen_utf8() instead of plain fopen()
>    avcodec/dvdsubdec: use av_fopen_utf8() instead of plain fopen()
> 
>   libavcodec/dvdsubdec.c            | 2 +-
>   libavfilter/af_firequalizer.c     | 2 +-
>   libavfilter/vf_deshake.c          | 2 +-
>   libavfilter/vf_psnr.c             | 2 +-
>   libavfilter/vf_signature.c        | 4 ++--
>   libavfilter/vf_ssim.c             | 2 +-
>   libavfilter/vf_vidstabdetect.c    | 2 +-
>   libavfilter/vf_vidstabtransform.c | 2 +-
>   libavfilter/vf_vmafmotion.c       | 2 +-
>   9 files changed, 10 insertions(+), 10 deletions(-)
> 
> [...]

Commit messages look fine to me now. I will leave the decision to others 
about the order of changes -- whether this patch-set comes first, or the 
fix for the CRT linking issue (possibly replacing this public function 
with a private copy).

Regards,
Tobias

_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [FFmpeg-devel] [PATCH v4 0/2] use av_fopen_utf8() instead of plain fopen()
  2022-05-18  7:01       ` [FFmpeg-devel] [PATCH v4 0/2] " Tobias Rapp
@ 2022-05-19 21:39         ` Soft Works
  0 siblings, 0 replies; 30+ messages in thread
From: Soft Works @ 2022-05-19 21:39 UTC (permalink / raw)
  To: Tobias Rapp, ffmpegagent, ffmpeg-devel; +Cc: Martin Storsjö



> -----Original Message-----
> From: Tobias Rapp <t.rapp@noa-archive.com>
> Sent: Wednesday, May 18, 2022 9:01 AM
> To: ffmpegagent <ffmpegagent@gmail.com>; ffmpeg-devel@ffmpeg.org
> Cc: Martin Storsjö <martin@martin.st>; Soft Works
> <softworkz@hotmail.com>
> Subject: Re: [PATCH v4 0/2] use av_fopen_utf8() instead of plain
> fopen()
> 
> On 17/05/2022 14:29, ffmpegagent wrote:
> > Unify file access operations by replacing usages of direct calls to
> posix
> > fopen()
> >
> > v2: Remove changes to fftools for now
> > v3: Add some additional replacements
> > v4: Fix and improve commit messages
> >
> > softworkz (2):
> >    avfilter: use av_fopen_utf8() instead of plain fopen()
> >    avcodec/dvdsubdec: use av_fopen_utf8() instead of plain fopen()
> >
> >   libavcodec/dvdsubdec.c            | 2 +-
> >   libavfilter/af_firequalizer.c     | 2 +-
> >   libavfilter/vf_deshake.c          | 2 +-
> >   libavfilter/vf_psnr.c             | 2 +-
> >   libavfilter/vf_signature.c        | 4 ++--
> >   libavfilter/vf_ssim.c             | 2 +-
> >   libavfilter/vf_vidstabdetect.c    | 2 +-
> >   libavfilter/vf_vidstabtransform.c | 2 +-
> >   libavfilter/vf_vmafmotion.c       | 2 +-
> >   9 files changed, 10 insertions(+), 10 deletions(-)
> >
> > [...]
> 
> Commit messages look fine to me now. I will leave the decision to
> others
> about the order of changes -- whether this patch-set comes first, or
> the
> fix for the CRT linking issue (possibly replacing this public function
> with a private copy).

To eliminate the question, I'm including that change in
the v5 of this patchset.

Thanks,
softworkz


_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

^ permalink raw reply	[flat|nested] 30+ messages in thread

* [FFmpeg-devel] [PATCH v5 0/3] use av_fopen_utf8() instead of plain fopen()
  2022-05-17 12:29     ` [FFmpeg-devel] [PATCH v4 " ffmpegagent
                         ` (2 preceding siblings ...)
  2022-05-18  7:01       ` [FFmpeg-devel] [PATCH v4 0/2] " Tobias Rapp
@ 2022-05-19 21:40       ` ffmpegagent
  2022-05-19 21:40         ` [FFmpeg-devel] [PATCH v5 1/3] avfilter: " softworkz
                           ` (3 more replies)
  3 siblings, 4 replies; 30+ messages in thread
From: ffmpegagent @ 2022-05-19 21:40 UTC (permalink / raw)
  To: ffmpeg-devel; +Cc: Martin Storsjö, softworkz, Tobias Rapp

Unify file access operations by replacing usages of direct calls to posix
fopen()

v2: Remove changes to fftools for now
v3: Add some additional replacements
v4: Fix and improve commit messages
v5: Add patch to remap ff_open in libavfilter for MSVC on Windows

softworkz (3):
  avfilter: use av_fopen_utf8() instead of plain fopen()
  avcodec/dvdsubdec: use av_fopen_utf8() instead of plain fopen()
  avfilter: Make avpriv_open a library-internal function on msvcrt

 libavcodec/dvdsubdec.c            | 2 +-
 libavfilter/Makefile              | 1 +
 libavfilter/af_firequalizer.c     | 2 +-
 libavfilter/file_open.c           | 1 +
 libavfilter/vf_deshake.c          | 2 +-
 libavfilter/vf_psnr.c             | 2 +-
 libavfilter/vf_signature.c        | 4 ++--
 libavfilter/vf_ssim.c             | 2 +-
 libavfilter/vf_vidstabdetect.c    | 2 +-
 libavfilter/vf_vidstabtransform.c | 2 +-
 libavfilter/vf_vmafmotion.c       | 2 +-
 11 files changed, 12 insertions(+), 10 deletions(-)
 create mode 100644 libavfilter/file_open.c


base-commit: 41a558fea06cc0a23b8d2d0dfb03ef6a25cf5100
Published-As: https://github.com/ffstaging/FFmpeg/releases/tag/pr-ffstaging-26%2Fsoftworkz%2Fsubmit_replace_fopen-v5
Fetch-It-Via: git fetch https://github.com/ffstaging/FFmpeg pr-ffstaging-26/softworkz/submit_replace_fopen-v5
Pull-Request: https://github.com/ffstaging/FFmpeg/pull/26

Range-diff vs v4:

 1:  7c455d7fa0 = 1:  bcafcfacea avfilter: use av_fopen_utf8() instead of plain fopen()
 2:  68192b1a1e = 2:  94d023ece3 avcodec/dvdsubdec: use av_fopen_utf8() instead of plain fopen()
 -:  ---------- > 3:  5e50103af3 avfilter: Make avpriv_open a library-internal function on msvcrt

-- 
ffmpeg-codebot
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

^ permalink raw reply	[flat|nested] 30+ messages in thread

* [FFmpeg-devel] [PATCH v5 1/3] avfilter: use av_fopen_utf8() instead of plain fopen()
  2022-05-19 21:40       ` [FFmpeg-devel] [PATCH v5 0/3] " ffmpegagent
@ 2022-05-19 21:40         ` softworkz
  2022-05-19 21:40         ` [FFmpeg-devel] [PATCH v5 2/3] avcodec/dvdsubdec: " softworkz
                           ` (2 subsequent siblings)
  3 siblings, 0 replies; 30+ messages in thread
From: softworkz @ 2022-05-19 21:40 UTC (permalink / raw)
  To: ffmpeg-devel; +Cc: Martin Storsjö, softworkz, Tobias Rapp

From: softworkz <softworkz@hotmail.com>

Unify file access operations by replacing usages of direct calls
to posix fopen() to prepare for long filename support on Windows.

Signed-off-by: softworkz <softworkz@hotmail.com>
---
 libavfilter/af_firequalizer.c     | 2 +-
 libavfilter/vf_deshake.c          | 2 +-
 libavfilter/vf_psnr.c             | 2 +-
 libavfilter/vf_signature.c        | 4 ++--
 libavfilter/vf_ssim.c             | 2 +-
 libavfilter/vf_vidstabdetect.c    | 2 +-
 libavfilter/vf_vidstabtransform.c | 2 +-
 libavfilter/vf_vmafmotion.c       | 2 +-
 8 files changed, 9 insertions(+), 9 deletions(-)

diff --git a/libavfilter/af_firequalizer.c b/libavfilter/af_firequalizer.c
index c19a2fe122..e1497dcef0 100644
--- a/libavfilter/af_firequalizer.c
+++ b/libavfilter/af_firequalizer.c
@@ -604,7 +604,7 @@ static int generate_kernel(AVFilterContext *ctx, const char *gain, const char *g
     if (ret < 0)
         return ret;
 
-    if (s->dumpfile && (!s->dump_buf || !s->analysis_rdft || !(dump_fp = fopen(s->dumpfile, "w"))))
+    if (s->dumpfile && (!s->dump_buf || !s->analysis_rdft || !(dump_fp = av_fopen_utf8(s->dumpfile, "w"))))
         av_log(ctx, AV_LOG_WARNING, "dumping failed.\n");
 
     vars[VAR_CHS] = inlink->ch_layout.nb_channels;
diff --git a/libavfilter/vf_deshake.c b/libavfilter/vf_deshake.c
index 4f28467bb2..dea69e11cd 100644
--- a/libavfilter/vf_deshake.c
+++ b/libavfilter/vf_deshake.c
@@ -353,7 +353,7 @@ static av_cold int init(AVFilterContext *ctx)
     }
 
     if (deshake->filename)
-        deshake->fp = fopen(deshake->filename, "w");
+        deshake->fp = av_fopen_utf8(deshake->filename, "w");
     if (deshake->fp)
         fwrite("Ori x, Avg x, Fin x, Ori y, Avg y, Fin y, Ori angle, Avg angle, Fin angle, Ori zoom, Avg zoom, Fin zoom\n", 1, 104, deshake->fp);
 
diff --git a/libavfilter/vf_psnr.c b/libavfilter/vf_psnr.c
index 19852eaa69..09c2a5164a 100644
--- a/libavfilter/vf_psnr.c
+++ b/libavfilter/vf_psnr.c
@@ -280,7 +280,7 @@ static av_cold int init(AVFilterContext *ctx)
         if (!strcmp(s->stats_file_str, "-")) {
             s->stats_file = stdout;
         } else {
-            s->stats_file = fopen(s->stats_file_str, "w");
+            s->stats_file = av_fopen_utf8(s->stats_file_str, "w");
             if (!s->stats_file) {
                 int err = AVERROR(errno);
                 char buf[128];
diff --git a/libavfilter/vf_signature.c b/libavfilter/vf_signature.c
index 4ca57ebf1d..904123fd4e 100644
--- a/libavfilter/vf_signature.c
+++ b/libavfilter/vf_signature.c
@@ -386,7 +386,7 @@ static int xml_export(AVFilterContext *ctx, StreamContext *sc, const char* filen
     FILE* f;
     unsigned int pot3[5] = { 3*3*3*3, 3*3*3, 3*3, 3, 1 };
 
-    f = fopen(filename, "w");
+    f = av_fopen_utf8(filename, "w");
     if (!f) {
         int err = AVERROR(EINVAL);
         char buf[128];
@@ -500,7 +500,7 @@ static int binary_export(AVFilterContext *ctx, StreamContext *sc, const char* fi
     if (!buffer)
         return AVERROR(ENOMEM);
 
-    f = fopen(filename, "wb");
+    f = av_fopen_utf8(filename, "wb");
     if (!f) {
         int err = AVERROR(EINVAL);
         char buf[128];
diff --git a/libavfilter/vf_ssim.c b/libavfilter/vf_ssim.c
index 32f313817d..4a82cbec06 100644
--- a/libavfilter/vf_ssim.c
+++ b/libavfilter/vf_ssim.c
@@ -404,7 +404,7 @@ static av_cold int init(AVFilterContext *ctx)
         if (!strcmp(s->stats_file_str, "-")) {
             s->stats_file = stdout;
         } else {
-            s->stats_file = fopen(s->stats_file_str, "w");
+            s->stats_file = av_fopen_utf8(s->stats_file_str, "w");
             if (!s->stats_file) {
                 int err = AVERROR(errno);
                 char buf[128];
diff --git a/libavfilter/vf_vidstabdetect.c b/libavfilter/vf_vidstabdetect.c
index 267a62ea9b..4acae5a3ea 100644
--- a/libavfilter/vf_vidstabdetect.c
+++ b/libavfilter/vf_vidstabdetect.c
@@ -126,7 +126,7 @@ static int config_input(AVFilterLink *inlink)
     av_log(ctx, AV_LOG_INFO, "          show = %d\n", s->conf.show);
     av_log(ctx, AV_LOG_INFO, "        result = %s\n", s->result);
 
-    s->f = fopen(s->result, "w");
+    s->f = av_fopen_utf8(s->result, "w");
     if (s->f == NULL) {
         av_log(ctx, AV_LOG_ERROR, "cannot open transform file %s\n", s->result);
         return AVERROR(EINVAL);
diff --git a/libavfilter/vf_vidstabtransform.c b/libavfilter/vf_vidstabtransform.c
index 4619e9b256..17214f039f 100644
--- a/libavfilter/vf_vidstabtransform.c
+++ b/libavfilter/vf_vidstabtransform.c
@@ -191,7 +191,7 @@ static int config_input(AVFilterLink *inlink)
         av_log(ctx, AV_LOG_INFO, "    zoomspeed = %g\n", tc->conf.zoomSpeed);
     av_log(ctx, AV_LOG_INFO, "    interpol  = %s\n", getInterpolationTypeName(tc->conf.interpolType));
 
-    f = fopen(tc->input, "r");
+    f = av_fopen_utf8(tc->input, "r");
     if (!f) {
         int ret = AVERROR(errno);
         av_log(ctx, AV_LOG_ERROR, "cannot open input file %s\n", tc->input);
diff --git a/libavfilter/vf_vmafmotion.c b/libavfilter/vf_vmafmotion.c
index 8b7e9b17ef..2ac67e5935 100644
--- a/libavfilter/vf_vmafmotion.c
+++ b/libavfilter/vf_vmafmotion.c
@@ -312,7 +312,7 @@ static av_cold int init(AVFilterContext *ctx)
         if (!strcmp(s->stats_file_str, "-")) {
             s->stats_file = stdout;
         } else {
-            s->stats_file = fopen(s->stats_file_str, "w");
+            s->stats_file = av_fopen_utf8(s->stats_file_str, "w");
             if (!s->stats_file) {
                 int err = AVERROR(errno);
                 char buf[128];
-- 
ffmpeg-codebot

_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

^ permalink raw reply	[flat|nested] 30+ messages in thread

* [FFmpeg-devel] [PATCH v5 2/3] avcodec/dvdsubdec: use av_fopen_utf8() instead of plain fopen()
  2022-05-19 21:40       ` [FFmpeg-devel] [PATCH v5 0/3] " ffmpegagent
  2022-05-19 21:40         ` [FFmpeg-devel] [PATCH v5 1/3] avfilter: " softworkz
@ 2022-05-19 21:40         ` softworkz
  2022-05-19 21:40         ` [FFmpeg-devel] [PATCH v5 3/3] avfilter: Make avpriv_open a library-internal function on msvcrt softworkz
  2022-05-19 23:15         ` [FFmpeg-devel] [PATCH v6 0/3] use av_fopen_utf8() instead of plain fopen() ffmpegagent
  3 siblings, 0 replies; 30+ messages in thread
From: softworkz @ 2022-05-19 21:40 UTC (permalink / raw)
  To: ffmpeg-devel; +Cc: Martin Storsjö, softworkz, Tobias Rapp

From: softworkz <softworkz@hotmail.com>

Unify file access operations by replacing usages of direct calls
to posix fopen() to prepare for long filename support on Windows.

Signed-off-by: softworkz <softworkz@hotmail.com>
---
 libavcodec/dvdsubdec.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavcodec/dvdsubdec.c b/libavcodec/dvdsubdec.c
index 30fe4d41de..19b78b3eb1 100644
--- a/libavcodec/dvdsubdec.c
+++ b/libavcodec/dvdsubdec.c
@@ -617,7 +617,7 @@ static int parse_ifo_palette(DVDSubContext *ctx, char *p)
     const uint8_t *cm = ff_crop_tab + MAX_NEG_CROP;
 
     ctx->has_palette = 0;
-    if ((ifo = fopen(p, "r")) == NULL) {
+    if ((ifo = av_fopen_utf8(p, "r")) == NULL) {
         av_log(ctx, AV_LOG_WARNING, "Unable to open IFO file \"%s\": %s\n", p, av_err2str(AVERROR(errno)));
         return AVERROR_EOF;
     }
-- 
ffmpeg-codebot

_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

^ permalink raw reply	[flat|nested] 30+ messages in thread

* [FFmpeg-devel] [PATCH v5 3/3] avfilter: Make avpriv_open a library-internal function on msvcrt
  2022-05-19 21:40       ` [FFmpeg-devel] [PATCH v5 0/3] " ffmpegagent
  2022-05-19 21:40         ` [FFmpeg-devel] [PATCH v5 1/3] avfilter: " softworkz
  2022-05-19 21:40         ` [FFmpeg-devel] [PATCH v5 2/3] avcodec/dvdsubdec: " softworkz
@ 2022-05-19 21:40         ` softworkz
  2022-05-19 23:15         ` [FFmpeg-devel] [PATCH v6 0/3] use av_fopen_utf8() instead of plain fopen() ffmpegagent
  3 siblings, 0 replies; 30+ messages in thread
From: softworkz @ 2022-05-19 21:40 UTC (permalink / raw)
  To: ffmpeg-devel; +Cc: Martin Storsjö, softworkz, Tobias Rapp

From: softworkz <softworkz@hotmail.com>

This applies the same change for libavfilter as commit
e743e7ae6ee7e535c4394bec6fe6650d2b0dbf65 did for the other libraries.

Original commit message:

Add one copy of the function into each of the libraries, similarly
to what we do for log2_tab. When using static libs, only one
copy of the file_open.o object file gets included, while when
using shared libraries, each of them get a copy of its own.

This fixes DLL builds with a statically linked C runtime, where
each DLL effectively has got its own instance of the C runtime,
where file descriptors can't be shared across runtimes.

On systems not using msvcrt, the function is not duplicated.

Based-on-patch-by: Martin Storsjö <martin@martin.st>
Signed-off-by: softworkz <softworkz@hotmail.com>
---
 libavfilter/Makefile    | 1 +
 libavfilter/file_open.c | 1 +
 2 files changed, 2 insertions(+)
 create mode 100644 libavfilter/file_open.c

diff --git a/libavfilter/Makefile b/libavfilter/Makefile
index ee2ea51e69..78ccfa37d3 100644
--- a/libavfilter/Makefile
+++ b/libavfilter/Makefile
@@ -23,6 +23,7 @@ OBJS = allfilters.o                                                     \
        version.o                                                        \
        video.o                                                          \
 
+OBJS-$(HAVE_LIBC_MSVCRT)                     += file_open.o
 OBJS-$(HAVE_THREADS)                         += pthread.o
 
 # subsystems
diff --git a/libavfilter/file_open.c b/libavfilter/file_open.c
new file mode 100644
index 0000000000..494a5d37a4
--- /dev/null
+++ b/libavfilter/file_open.c
@@ -0,0 +1 @@
+#include "libavutil/file_open.c"
-- 
ffmpeg-codebot
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

^ permalink raw reply	[flat|nested] 30+ messages in thread

* [FFmpeg-devel] [PATCH v6 0/3] use av_fopen_utf8() instead of plain fopen()
  2022-05-19 21:40       ` [FFmpeg-devel] [PATCH v5 0/3] " ffmpegagent
                           ` (2 preceding siblings ...)
  2022-05-19 21:40         ` [FFmpeg-devel] [PATCH v5 3/3] avfilter: Make avpriv_open a library-internal function on msvcrt softworkz
@ 2022-05-19 23:15         ` ffmpegagent
  2022-05-19 23:15           ` [FFmpeg-devel] [PATCH v6 1/3] avfilter: " softworkz
                             ` (3 more replies)
  3 siblings, 4 replies; 30+ messages in thread
From: ffmpegagent @ 2022-05-19 23:15 UTC (permalink / raw)
  To: ffmpeg-devel; +Cc: Martin Storsjö, softworkz, Tobias Rapp

Unify file access operations by replacing usages of direct calls to posix
fopen()

v2: Remove changes to fftools for now
v3: Add some additional replacements
v4: Fix and improve commit messages
v5: Add patch to remap ff_open in libavfilter for MSVC on Windows
v6: Add avfilter/file_open.c to "Files without standard license headers"
list

softworkz (3):
  avfilter: use av_fopen_utf8() instead of plain fopen()
  avcodec/dvdsubdec: use av_fopen_utf8() instead of plain fopen()
  avfilter: Make avpriv_open a library-internal function on msvcrt

 libavcodec/dvdsubdec.c            | 2 +-
 libavfilter/Makefile              | 1 +
 libavfilter/af_firequalizer.c     | 2 +-
 libavfilter/file_open.c           | 1 +
 libavfilter/vf_deshake.c          | 2 +-
 libavfilter/vf_psnr.c             | 2 +-
 libavfilter/vf_signature.c        | 4 ++--
 libavfilter/vf_ssim.c             | 2 +-
 libavfilter/vf_vidstabdetect.c    | 2 +-
 libavfilter/vf_vidstabtransform.c | 2 +-
 libavfilter/vf_vmafmotion.c       | 2 +-
 tests/ref/fate/source             | 1 +
 12 files changed, 13 insertions(+), 10 deletions(-)
 create mode 100644 libavfilter/file_open.c


base-commit: 41a558fea06cc0a23b8d2d0dfb03ef6a25cf5100
Published-As: https://github.com/ffstaging/FFmpeg/releases/tag/pr-ffstaging-26%2Fsoftworkz%2Fsubmit_replace_fopen-v6
Fetch-It-Via: git fetch https://github.com/ffstaging/FFmpeg pr-ffstaging-26/softworkz/submit_replace_fopen-v6
Pull-Request: https://github.com/ffstaging/FFmpeg/pull/26

Range-diff vs v5:

 1:  bcafcfacea = 1:  bcafcfacea avfilter: use av_fopen_utf8() instead of plain fopen()
 2:  94d023ece3 = 2:  94d023ece3 avcodec/dvdsubdec: use av_fopen_utf8() instead of plain fopen()
 3:  5e50103af3 ! 3:  4035d5dd7b avfilter: Make avpriv_open a library-internal function on msvcrt
     @@ libavfilter/Makefile: OBJS = allfilters.o
       ## libavfilter/file_open.c (new) ##
      @@
      +#include "libavutil/file_open.c"
     +
     + ## tests/ref/fate/source ##
     +@@ tests/ref/fate/source: libavcodec/reverse.c
     + libavdevice/file_open.c
     + libavdevice/reverse.c
     + libavfilter/af_arnndn.c
     ++libavfilter/file_open.c
     + libavfilter/log2_tab.c
     + libavformat/file_open.c
     + libavformat/golomb_tab.c

-- 
ffmpeg-codebot
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

^ permalink raw reply	[flat|nested] 30+ messages in thread

* [FFmpeg-devel] [PATCH v6 1/3] avfilter: use av_fopen_utf8() instead of plain fopen()
  2022-05-19 23:15         ` [FFmpeg-devel] [PATCH v6 0/3] use av_fopen_utf8() instead of plain fopen() ffmpegagent
@ 2022-05-19 23:15           ` softworkz
  2022-05-19 23:15           ` [FFmpeg-devel] [PATCH v6 2/3] avcodec/dvdsubdec: " softworkz
                             ` (2 subsequent siblings)
  3 siblings, 0 replies; 30+ messages in thread
From: softworkz @ 2022-05-19 23:15 UTC (permalink / raw)
  To: ffmpeg-devel; +Cc: Martin Storsjö, softworkz, Tobias Rapp

From: softworkz <softworkz@hotmail.com>

Unify file access operations by replacing usages of direct calls
to posix fopen() to prepare for long filename support on Windows.

Signed-off-by: softworkz <softworkz@hotmail.com>
---
 libavfilter/af_firequalizer.c     | 2 +-
 libavfilter/vf_deshake.c          | 2 +-
 libavfilter/vf_psnr.c             | 2 +-
 libavfilter/vf_signature.c        | 4 ++--
 libavfilter/vf_ssim.c             | 2 +-
 libavfilter/vf_vidstabdetect.c    | 2 +-
 libavfilter/vf_vidstabtransform.c | 2 +-
 libavfilter/vf_vmafmotion.c       | 2 +-
 8 files changed, 9 insertions(+), 9 deletions(-)

diff --git a/libavfilter/af_firequalizer.c b/libavfilter/af_firequalizer.c
index c19a2fe122..e1497dcef0 100644
--- a/libavfilter/af_firequalizer.c
+++ b/libavfilter/af_firequalizer.c
@@ -604,7 +604,7 @@ static int generate_kernel(AVFilterContext *ctx, const char *gain, const char *g
     if (ret < 0)
         return ret;
 
-    if (s->dumpfile && (!s->dump_buf || !s->analysis_rdft || !(dump_fp = fopen(s->dumpfile, "w"))))
+    if (s->dumpfile && (!s->dump_buf || !s->analysis_rdft || !(dump_fp = av_fopen_utf8(s->dumpfile, "w"))))
         av_log(ctx, AV_LOG_WARNING, "dumping failed.\n");
 
     vars[VAR_CHS] = inlink->ch_layout.nb_channels;
diff --git a/libavfilter/vf_deshake.c b/libavfilter/vf_deshake.c
index 4f28467bb2..dea69e11cd 100644
--- a/libavfilter/vf_deshake.c
+++ b/libavfilter/vf_deshake.c
@@ -353,7 +353,7 @@ static av_cold int init(AVFilterContext *ctx)
     }
 
     if (deshake->filename)
-        deshake->fp = fopen(deshake->filename, "w");
+        deshake->fp = av_fopen_utf8(deshake->filename, "w");
     if (deshake->fp)
         fwrite("Ori x, Avg x, Fin x, Ori y, Avg y, Fin y, Ori angle, Avg angle, Fin angle, Ori zoom, Avg zoom, Fin zoom\n", 1, 104, deshake->fp);
 
diff --git a/libavfilter/vf_psnr.c b/libavfilter/vf_psnr.c
index 19852eaa69..09c2a5164a 100644
--- a/libavfilter/vf_psnr.c
+++ b/libavfilter/vf_psnr.c
@@ -280,7 +280,7 @@ static av_cold int init(AVFilterContext *ctx)
         if (!strcmp(s->stats_file_str, "-")) {
             s->stats_file = stdout;
         } else {
-            s->stats_file = fopen(s->stats_file_str, "w");
+            s->stats_file = av_fopen_utf8(s->stats_file_str, "w");
             if (!s->stats_file) {
                 int err = AVERROR(errno);
                 char buf[128];
diff --git a/libavfilter/vf_signature.c b/libavfilter/vf_signature.c
index 4ca57ebf1d..904123fd4e 100644
--- a/libavfilter/vf_signature.c
+++ b/libavfilter/vf_signature.c
@@ -386,7 +386,7 @@ static int xml_export(AVFilterContext *ctx, StreamContext *sc, const char* filen
     FILE* f;
     unsigned int pot3[5] = { 3*3*3*3, 3*3*3, 3*3, 3, 1 };
 
-    f = fopen(filename, "w");
+    f = av_fopen_utf8(filename, "w");
     if (!f) {
         int err = AVERROR(EINVAL);
         char buf[128];
@@ -500,7 +500,7 @@ static int binary_export(AVFilterContext *ctx, StreamContext *sc, const char* fi
     if (!buffer)
         return AVERROR(ENOMEM);
 
-    f = fopen(filename, "wb");
+    f = av_fopen_utf8(filename, "wb");
     if (!f) {
         int err = AVERROR(EINVAL);
         char buf[128];
diff --git a/libavfilter/vf_ssim.c b/libavfilter/vf_ssim.c
index 32f313817d..4a82cbec06 100644
--- a/libavfilter/vf_ssim.c
+++ b/libavfilter/vf_ssim.c
@@ -404,7 +404,7 @@ static av_cold int init(AVFilterContext *ctx)
         if (!strcmp(s->stats_file_str, "-")) {
             s->stats_file = stdout;
         } else {
-            s->stats_file = fopen(s->stats_file_str, "w");
+            s->stats_file = av_fopen_utf8(s->stats_file_str, "w");
             if (!s->stats_file) {
                 int err = AVERROR(errno);
                 char buf[128];
diff --git a/libavfilter/vf_vidstabdetect.c b/libavfilter/vf_vidstabdetect.c
index 267a62ea9b..4acae5a3ea 100644
--- a/libavfilter/vf_vidstabdetect.c
+++ b/libavfilter/vf_vidstabdetect.c
@@ -126,7 +126,7 @@ static int config_input(AVFilterLink *inlink)
     av_log(ctx, AV_LOG_INFO, "          show = %d\n", s->conf.show);
     av_log(ctx, AV_LOG_INFO, "        result = %s\n", s->result);
 
-    s->f = fopen(s->result, "w");
+    s->f = av_fopen_utf8(s->result, "w");
     if (s->f == NULL) {
         av_log(ctx, AV_LOG_ERROR, "cannot open transform file %s\n", s->result);
         return AVERROR(EINVAL);
diff --git a/libavfilter/vf_vidstabtransform.c b/libavfilter/vf_vidstabtransform.c
index 4619e9b256..17214f039f 100644
--- a/libavfilter/vf_vidstabtransform.c
+++ b/libavfilter/vf_vidstabtransform.c
@@ -191,7 +191,7 @@ static int config_input(AVFilterLink *inlink)
         av_log(ctx, AV_LOG_INFO, "    zoomspeed = %g\n", tc->conf.zoomSpeed);
     av_log(ctx, AV_LOG_INFO, "    interpol  = %s\n", getInterpolationTypeName(tc->conf.interpolType));
 
-    f = fopen(tc->input, "r");
+    f = av_fopen_utf8(tc->input, "r");
     if (!f) {
         int ret = AVERROR(errno);
         av_log(ctx, AV_LOG_ERROR, "cannot open input file %s\n", tc->input);
diff --git a/libavfilter/vf_vmafmotion.c b/libavfilter/vf_vmafmotion.c
index 8b7e9b17ef..2ac67e5935 100644
--- a/libavfilter/vf_vmafmotion.c
+++ b/libavfilter/vf_vmafmotion.c
@@ -312,7 +312,7 @@ static av_cold int init(AVFilterContext *ctx)
         if (!strcmp(s->stats_file_str, "-")) {
             s->stats_file = stdout;
         } else {
-            s->stats_file = fopen(s->stats_file_str, "w");
+            s->stats_file = av_fopen_utf8(s->stats_file_str, "w");
             if (!s->stats_file) {
                 int err = AVERROR(errno);
                 char buf[128];
-- 
ffmpeg-codebot

_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

^ permalink raw reply	[flat|nested] 30+ messages in thread

* [FFmpeg-devel] [PATCH v6 2/3] avcodec/dvdsubdec: use av_fopen_utf8() instead of plain fopen()
  2022-05-19 23:15         ` [FFmpeg-devel] [PATCH v6 0/3] use av_fopen_utf8() instead of plain fopen() ffmpegagent
  2022-05-19 23:15           ` [FFmpeg-devel] [PATCH v6 1/3] avfilter: " softworkz
@ 2022-05-19 23:15           ` softworkz
  2022-05-19 23:15           ` [FFmpeg-devel] [PATCH v6 3/3] avfilter: Make avpriv_open a library-internal function on msvcrt softworkz
  2022-05-23 11:26           ` [FFmpeg-devel] [PATCH v7 0/2] use av_fopen_utf8() instead of plain fopen() ffmpegagent
  3 siblings, 0 replies; 30+ messages in thread
From: softworkz @ 2022-05-19 23:15 UTC (permalink / raw)
  To: ffmpeg-devel; +Cc: Martin Storsjö, softworkz, Tobias Rapp

From: softworkz <softworkz@hotmail.com>

Unify file access operations by replacing usages of direct calls
to posix fopen() to prepare for long filename support on Windows.

Signed-off-by: softworkz <softworkz@hotmail.com>
---
 libavcodec/dvdsubdec.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavcodec/dvdsubdec.c b/libavcodec/dvdsubdec.c
index 30fe4d41de..19b78b3eb1 100644
--- a/libavcodec/dvdsubdec.c
+++ b/libavcodec/dvdsubdec.c
@@ -617,7 +617,7 @@ static int parse_ifo_palette(DVDSubContext *ctx, char *p)
     const uint8_t *cm = ff_crop_tab + MAX_NEG_CROP;
 
     ctx->has_palette = 0;
-    if ((ifo = fopen(p, "r")) == NULL) {
+    if ((ifo = av_fopen_utf8(p, "r")) == NULL) {
         av_log(ctx, AV_LOG_WARNING, "Unable to open IFO file \"%s\": %s\n", p, av_err2str(AVERROR(errno)));
         return AVERROR_EOF;
     }
-- 
ffmpeg-codebot

_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

^ permalink raw reply	[flat|nested] 30+ messages in thread

* [FFmpeg-devel] [PATCH v6 3/3] avfilter: Make avpriv_open a library-internal function on msvcrt
  2022-05-19 23:15         ` [FFmpeg-devel] [PATCH v6 0/3] use av_fopen_utf8() instead of plain fopen() ffmpegagent
  2022-05-19 23:15           ` [FFmpeg-devel] [PATCH v6 1/3] avfilter: " softworkz
  2022-05-19 23:15           ` [FFmpeg-devel] [PATCH v6 2/3] avcodec/dvdsubdec: " softworkz
@ 2022-05-19 23:15           ` softworkz
  2022-05-23 11:26           ` [FFmpeg-devel] [PATCH v7 0/2] use av_fopen_utf8() instead of plain fopen() ffmpegagent
  3 siblings, 0 replies; 30+ messages in thread
From: softworkz @ 2022-05-19 23:15 UTC (permalink / raw)
  To: ffmpeg-devel; +Cc: Martin Storsjö, softworkz, Tobias Rapp

From: softworkz <softworkz@hotmail.com>

This applies the same change for libavfilter as commit
e743e7ae6ee7e535c4394bec6fe6650d2b0dbf65 did for the other libraries.

Original commit message:

Add one copy of the function into each of the libraries, similarly
to what we do for log2_tab. When using static libs, only one
copy of the file_open.o object file gets included, while when
using shared libraries, each of them get a copy of its own.

This fixes DLL builds with a statically linked C runtime, where
each DLL effectively has got its own instance of the C runtime,
where file descriptors can't be shared across runtimes.

On systems not using msvcrt, the function is not duplicated.

Based-on-patch-by: Martin Storsjö <martin@martin.st>
Signed-off-by: softworkz <softworkz@hotmail.com>
---
 libavfilter/Makefile    | 1 +
 libavfilter/file_open.c | 1 +
 tests/ref/fate/source   | 1 +
 3 files changed, 3 insertions(+)
 create mode 100644 libavfilter/file_open.c

diff --git a/libavfilter/Makefile b/libavfilter/Makefile
index ee2ea51e69..78ccfa37d3 100644
--- a/libavfilter/Makefile
+++ b/libavfilter/Makefile
@@ -23,6 +23,7 @@ OBJS = allfilters.o                                                     \
        version.o                                                        \
        video.o                                                          \
 
+OBJS-$(HAVE_LIBC_MSVCRT)                     += file_open.o
 OBJS-$(HAVE_THREADS)                         += pthread.o
 
 # subsystems
diff --git a/libavfilter/file_open.c b/libavfilter/file_open.c
new file mode 100644
index 0000000000..494a5d37a4
--- /dev/null
+++ b/libavfilter/file_open.c
@@ -0,0 +1 @@
+#include "libavutil/file_open.c"
diff --git a/tests/ref/fate/source b/tests/ref/fate/source
index 69dcdc4f27..16ea7ef9c1 100644
--- a/tests/ref/fate/source
+++ b/tests/ref/fate/source
@@ -8,6 +8,7 @@ libavcodec/reverse.c
 libavdevice/file_open.c
 libavdevice/reverse.c
 libavfilter/af_arnndn.c
+libavfilter/file_open.c
 libavfilter/log2_tab.c
 libavformat/file_open.c
 libavformat/golomb_tab.c
-- 
ffmpeg-codebot
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

^ permalink raw reply	[flat|nested] 30+ messages in thread

* [FFmpeg-devel] [PATCH v7 0/2] use av_fopen_utf8() instead of plain fopen()
  2022-05-19 23:15         ` [FFmpeg-devel] [PATCH v6 0/3] use av_fopen_utf8() instead of plain fopen() ffmpegagent
                             ` (2 preceding siblings ...)
  2022-05-19 23:15           ` [FFmpeg-devel] [PATCH v6 3/3] avfilter: Make avpriv_open a library-internal function on msvcrt softworkz
@ 2022-05-23 11:26           ` ffmpegagent
  2022-05-23 11:26             ` [FFmpeg-devel] [PATCH v7 1/2] avfilter: " softworkz
                               ` (2 more replies)
  3 siblings, 3 replies; 30+ messages in thread
From: ffmpegagent @ 2022-05-23 11:26 UTC (permalink / raw)
  To: ffmpeg-devel; +Cc: Martin Storsjö, softworkz, Tobias Rapp

Unify file access operations by replacing usages of direct calls to posix
fopen()

v2: Remove changes to fftools for now
v3: Add some additional replacements
v4: Fix and improve commit messages
v5: Add patch to remap ff_open in libavfilter for MSVC on Windows
v6: Add avfilter/file_open.c to "Files without standard license headers"
list
v7: Rebase and use the new avpriv_fopen_utf8() instead

softworkz (2):
  avfilter: use av_fopen_utf8() instead of plain fopen()
  avcodec/dvdsubdec: use av_fopen_utf8() instead of plain fopen()

 libavcodec/dvdsubdec.c            | 2 +-
 libavfilter/af_firequalizer.c     | 2 +-
 libavfilter/vf_deshake.c          | 2 +-
 libavfilter/vf_psnr.c             | 2 +-
 libavfilter/vf_signature.c        | 4 ++--
 libavfilter/vf_ssim.c             | 2 +-
 libavfilter/vf_vidstabdetect.c    | 2 +-
 libavfilter/vf_vidstabtransform.c | 2 +-
 libavfilter/vf_vmafmotion.c       | 2 +-
 9 files changed, 10 insertions(+), 10 deletions(-)


base-commit: 6076dbcb55d0c9b6693d1acad12a63f7268301aa
Published-As: https://github.com/ffstaging/FFmpeg/releases/tag/pr-ffstaging-26%2Fsoftworkz%2Fsubmit_replace_fopen-v7
Fetch-It-Via: git fetch https://github.com/ffstaging/FFmpeg pr-ffstaging-26/softworkz/submit_replace_fopen-v7
Pull-Request: https://github.com/ffstaging/FFmpeg/pull/26

Range-diff vs v6:

 1:  bcafcfacea ! 1:  aabfa10d44 avfilter: use av_fopen_utf8() instead of plain fopen()
     @@ libavfilter/af_firequalizer.c: static int generate_kernel(AVFilterContext *ctx,
               return ret;
       
      -    if (s->dumpfile && (!s->dump_buf || !s->analysis_rdft || !(dump_fp = fopen(s->dumpfile, "w"))))
     -+    if (s->dumpfile && (!s->dump_buf || !s->analysis_rdft || !(dump_fp = av_fopen_utf8(s->dumpfile, "w"))))
     ++    if (s->dumpfile && (!s->dump_buf || !s->analysis_rdft || !(dump_fp = avpriv_fopen_utf8(s->dumpfile, "w"))))
               av_log(ctx, AV_LOG_WARNING, "dumping failed.\n");
       
           vars[VAR_CHS] = inlink->ch_layout.nb_channels;
     @@ libavfilter/vf_deshake.c: static av_cold int init(AVFilterContext *ctx)
       
           if (deshake->filename)
      -        deshake->fp = fopen(deshake->filename, "w");
     -+        deshake->fp = av_fopen_utf8(deshake->filename, "w");
     ++        deshake->fp = avpriv_fopen_utf8(deshake->filename, "w");
           if (deshake->fp)
               fwrite("Ori x, Avg x, Fin x, Ori y, Avg y, Fin y, Ori angle, Avg angle, Fin angle, Ori zoom, Avg zoom, Fin zoom\n", 1, 104, deshake->fp);
       
     @@ libavfilter/vf_psnr.c: static av_cold int init(AVFilterContext *ctx)
                   s->stats_file = stdout;
               } else {
      -            s->stats_file = fopen(s->stats_file_str, "w");
     -+            s->stats_file = av_fopen_utf8(s->stats_file_str, "w");
     ++            s->stats_file = avpriv_fopen_utf8(s->stats_file_str, "w");
                   if (!s->stats_file) {
                       int err = AVERROR(errno);
                       char buf[128];
     @@ libavfilter/vf_signature.c: static int xml_export(AVFilterContext *ctx, StreamCo
           unsigned int pot3[5] = { 3*3*3*3, 3*3*3, 3*3, 3, 1 };
       
      -    f = fopen(filename, "w");
     -+    f = av_fopen_utf8(filename, "w");
     ++    f = avpriv_fopen_utf8(filename, "w");
           if (!f) {
               int err = AVERROR(EINVAL);
               char buf[128];
     @@ libavfilter/vf_signature.c: static int binary_export(AVFilterContext *ctx, Strea
               return AVERROR(ENOMEM);
       
      -    f = fopen(filename, "wb");
     -+    f = av_fopen_utf8(filename, "wb");
     ++    f = avpriv_fopen_utf8(filename, "wb");
           if (!f) {
               int err = AVERROR(EINVAL);
               char buf[128];
     @@ libavfilter/vf_ssim.c: static av_cold int init(AVFilterContext *ctx)
                   s->stats_file = stdout;
               } else {
      -            s->stats_file = fopen(s->stats_file_str, "w");
     -+            s->stats_file = av_fopen_utf8(s->stats_file_str, "w");
     ++            s->stats_file = avpriv_fopen_utf8(s->stats_file_str, "w");
                   if (!s->stats_file) {
                       int err = AVERROR(errno);
                       char buf[128];
     @@ libavfilter/vf_vidstabdetect.c: static int config_input(AVFilterLink *inlink)
           av_log(ctx, AV_LOG_INFO, "        result = %s\n", s->result);
       
      -    s->f = fopen(s->result, "w");
     -+    s->f = av_fopen_utf8(s->result, "w");
     ++    s->f = avpriv_fopen_utf8(s->result, "w");
           if (s->f == NULL) {
               av_log(ctx, AV_LOG_ERROR, "cannot open transform file %s\n", s->result);
               return AVERROR(EINVAL);
     @@ libavfilter/vf_vidstabtransform.c: static int config_input(AVFilterLink *inlink)
           av_log(ctx, AV_LOG_INFO, "    interpol  = %s\n", getInterpolationTypeName(tc->conf.interpolType));
       
      -    f = fopen(tc->input, "r");
     -+    f = av_fopen_utf8(tc->input, "r");
     ++    f = avpriv_fopen_utf8(tc->input, "r");
           if (!f) {
               int ret = AVERROR(errno);
               av_log(ctx, AV_LOG_ERROR, "cannot open input file %s\n", tc->input);
     @@ libavfilter/vf_vmafmotion.c: static av_cold int init(AVFilterContext *ctx)
                   s->stats_file = stdout;
               } else {
      -            s->stats_file = fopen(s->stats_file_str, "w");
     -+            s->stats_file = av_fopen_utf8(s->stats_file_str, "w");
     ++            s->stats_file = avpriv_fopen_utf8(s->stats_file_str, "w");
                   if (!s->stats_file) {
                       int err = AVERROR(errno);
                       char buf[128];
 2:  94d023ece3 ! 2:  a5266db995 avcodec/dvdsubdec: use av_fopen_utf8() instead of plain fopen()
     @@ libavcodec/dvdsubdec.c: static int parse_ifo_palette(DVDSubContext *ctx, char *p
       
           ctx->has_palette = 0;
      -    if ((ifo = fopen(p, "r")) == NULL) {
     -+    if ((ifo = av_fopen_utf8(p, "r")) == NULL) {
     ++    if ((ifo = avpriv_fopen_utf8(p, "r")) == NULL) {
               av_log(ctx, AV_LOG_WARNING, "Unable to open IFO file \"%s\": %s\n", p, av_err2str(AVERROR(errno)));
               return AVERROR_EOF;
           }
 3:  4035d5dd7b < -:  ---------- avfilter: Make avpriv_open a library-internal function on msvcrt

-- 
ffmpeg-codebot
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

^ permalink raw reply	[flat|nested] 30+ messages in thread

* [FFmpeg-devel] [PATCH v7 1/2] avfilter: use av_fopen_utf8() instead of plain fopen()
  2022-05-23 11:26           ` [FFmpeg-devel] [PATCH v7 0/2] use av_fopen_utf8() instead of plain fopen() ffmpegagent
@ 2022-05-23 11:26             ` softworkz
  2022-05-23 11:26             ` [FFmpeg-devel] [PATCH v7 2/2] avcodec/dvdsubdec: " softworkz
  2022-05-24  8:55             ` [FFmpeg-devel] [PATCH v7 0/2] " Martin Storsjö
  2 siblings, 0 replies; 30+ messages in thread
From: softworkz @ 2022-05-23 11:26 UTC (permalink / raw)
  To: ffmpeg-devel; +Cc: Martin Storsjö, softworkz, Tobias Rapp

From: softworkz <softworkz@hotmail.com>

Unify file access operations by replacing usages of direct calls
to posix fopen() to prepare for long filename support on Windows.

Signed-off-by: softworkz <softworkz@hotmail.com>
---
 libavfilter/af_firequalizer.c     | 2 +-
 libavfilter/vf_deshake.c          | 2 +-
 libavfilter/vf_psnr.c             | 2 +-
 libavfilter/vf_signature.c        | 4 ++--
 libavfilter/vf_ssim.c             | 2 +-
 libavfilter/vf_vidstabdetect.c    | 2 +-
 libavfilter/vf_vidstabtransform.c | 2 +-
 libavfilter/vf_vmafmotion.c       | 2 +-
 8 files changed, 9 insertions(+), 9 deletions(-)

diff --git a/libavfilter/af_firequalizer.c b/libavfilter/af_firequalizer.c
index c19a2fe122..85bdb59209 100644
--- a/libavfilter/af_firequalizer.c
+++ b/libavfilter/af_firequalizer.c
@@ -604,7 +604,7 @@ static int generate_kernel(AVFilterContext *ctx, const char *gain, const char *g
     if (ret < 0)
         return ret;
 
-    if (s->dumpfile && (!s->dump_buf || !s->analysis_rdft || !(dump_fp = fopen(s->dumpfile, "w"))))
+    if (s->dumpfile && (!s->dump_buf || !s->analysis_rdft || !(dump_fp = avpriv_fopen_utf8(s->dumpfile, "w"))))
         av_log(ctx, AV_LOG_WARNING, "dumping failed.\n");
 
     vars[VAR_CHS] = inlink->ch_layout.nb_channels;
diff --git a/libavfilter/vf_deshake.c b/libavfilter/vf_deshake.c
index 4f28467bb2..b37cffba9d 100644
--- a/libavfilter/vf_deshake.c
+++ b/libavfilter/vf_deshake.c
@@ -353,7 +353,7 @@ static av_cold int init(AVFilterContext *ctx)
     }
 
     if (deshake->filename)
-        deshake->fp = fopen(deshake->filename, "w");
+        deshake->fp = avpriv_fopen_utf8(deshake->filename, "w");
     if (deshake->fp)
         fwrite("Ori x, Avg x, Fin x, Ori y, Avg y, Fin y, Ori angle, Avg angle, Fin angle, Ori zoom, Avg zoom, Fin zoom\n", 1, 104, deshake->fp);
 
diff --git a/libavfilter/vf_psnr.c b/libavfilter/vf_psnr.c
index 19852eaa69..fdfd211401 100644
--- a/libavfilter/vf_psnr.c
+++ b/libavfilter/vf_psnr.c
@@ -280,7 +280,7 @@ static av_cold int init(AVFilterContext *ctx)
         if (!strcmp(s->stats_file_str, "-")) {
             s->stats_file = stdout;
         } else {
-            s->stats_file = fopen(s->stats_file_str, "w");
+            s->stats_file = avpriv_fopen_utf8(s->stats_file_str, "w");
             if (!s->stats_file) {
                 int err = AVERROR(errno);
                 char buf[128];
diff --git a/libavfilter/vf_signature.c b/libavfilter/vf_signature.c
index 4ca57ebf1d..5cff149756 100644
--- a/libavfilter/vf_signature.c
+++ b/libavfilter/vf_signature.c
@@ -386,7 +386,7 @@ static int xml_export(AVFilterContext *ctx, StreamContext *sc, const char* filen
     FILE* f;
     unsigned int pot3[5] = { 3*3*3*3, 3*3*3, 3*3, 3, 1 };
 
-    f = fopen(filename, "w");
+    f = avpriv_fopen_utf8(filename, "w");
     if (!f) {
         int err = AVERROR(EINVAL);
         char buf[128];
@@ -500,7 +500,7 @@ static int binary_export(AVFilterContext *ctx, StreamContext *sc, const char* fi
     if (!buffer)
         return AVERROR(ENOMEM);
 
-    f = fopen(filename, "wb");
+    f = avpriv_fopen_utf8(filename, "wb");
     if (!f) {
         int err = AVERROR(EINVAL);
         char buf[128];
diff --git a/libavfilter/vf_ssim.c b/libavfilter/vf_ssim.c
index 32f313817d..bceb3288ef 100644
--- a/libavfilter/vf_ssim.c
+++ b/libavfilter/vf_ssim.c
@@ -404,7 +404,7 @@ static av_cold int init(AVFilterContext *ctx)
         if (!strcmp(s->stats_file_str, "-")) {
             s->stats_file = stdout;
         } else {
-            s->stats_file = fopen(s->stats_file_str, "w");
+            s->stats_file = avpriv_fopen_utf8(s->stats_file_str, "w");
             if (!s->stats_file) {
                 int err = AVERROR(errno);
                 char buf[128];
diff --git a/libavfilter/vf_vidstabdetect.c b/libavfilter/vf_vidstabdetect.c
index 267a62ea9b..044911ec27 100644
--- a/libavfilter/vf_vidstabdetect.c
+++ b/libavfilter/vf_vidstabdetect.c
@@ -126,7 +126,7 @@ static int config_input(AVFilterLink *inlink)
     av_log(ctx, AV_LOG_INFO, "          show = %d\n", s->conf.show);
     av_log(ctx, AV_LOG_INFO, "        result = %s\n", s->result);
 
-    s->f = fopen(s->result, "w");
+    s->f = avpriv_fopen_utf8(s->result, "w");
     if (s->f == NULL) {
         av_log(ctx, AV_LOG_ERROR, "cannot open transform file %s\n", s->result);
         return AVERROR(EINVAL);
diff --git a/libavfilter/vf_vidstabtransform.c b/libavfilter/vf_vidstabtransform.c
index 4619e9b256..de303554cd 100644
--- a/libavfilter/vf_vidstabtransform.c
+++ b/libavfilter/vf_vidstabtransform.c
@@ -191,7 +191,7 @@ static int config_input(AVFilterLink *inlink)
         av_log(ctx, AV_LOG_INFO, "    zoomspeed = %g\n", tc->conf.zoomSpeed);
     av_log(ctx, AV_LOG_INFO, "    interpol  = %s\n", getInterpolationTypeName(tc->conf.interpolType));
 
-    f = fopen(tc->input, "r");
+    f = avpriv_fopen_utf8(tc->input, "r");
     if (!f) {
         int ret = AVERROR(errno);
         av_log(ctx, AV_LOG_ERROR, "cannot open input file %s\n", tc->input);
diff --git a/libavfilter/vf_vmafmotion.c b/libavfilter/vf_vmafmotion.c
index 8b7e9b17ef..6ae968f7e9 100644
--- a/libavfilter/vf_vmafmotion.c
+++ b/libavfilter/vf_vmafmotion.c
@@ -312,7 +312,7 @@ static av_cold int init(AVFilterContext *ctx)
         if (!strcmp(s->stats_file_str, "-")) {
             s->stats_file = stdout;
         } else {
-            s->stats_file = fopen(s->stats_file_str, "w");
+            s->stats_file = avpriv_fopen_utf8(s->stats_file_str, "w");
             if (!s->stats_file) {
                 int err = AVERROR(errno);
                 char buf[128];
-- 
ffmpeg-codebot

_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

^ permalink raw reply	[flat|nested] 30+ messages in thread

* [FFmpeg-devel] [PATCH v7 2/2] avcodec/dvdsubdec: use av_fopen_utf8() instead of plain fopen()
  2022-05-23 11:26           ` [FFmpeg-devel] [PATCH v7 0/2] use av_fopen_utf8() instead of plain fopen() ffmpegagent
  2022-05-23 11:26             ` [FFmpeg-devel] [PATCH v7 1/2] avfilter: " softworkz
@ 2022-05-23 11:26             ` softworkz
  2022-05-24  8:55             ` [FFmpeg-devel] [PATCH v7 0/2] " Martin Storsjö
  2 siblings, 0 replies; 30+ messages in thread
From: softworkz @ 2022-05-23 11:26 UTC (permalink / raw)
  To: ffmpeg-devel; +Cc: Martin Storsjö, softworkz, Tobias Rapp

From: softworkz <softworkz@hotmail.com>

Unify file access operations by replacing usages of direct calls
to posix fopen() to prepare for long filename support on Windows.

Signed-off-by: softworkz <softworkz@hotmail.com>
---
 libavcodec/dvdsubdec.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavcodec/dvdsubdec.c b/libavcodec/dvdsubdec.c
index 30fe4d41de..b54073393e 100644
--- a/libavcodec/dvdsubdec.c
+++ b/libavcodec/dvdsubdec.c
@@ -617,7 +617,7 @@ static int parse_ifo_palette(DVDSubContext *ctx, char *p)
     const uint8_t *cm = ff_crop_tab + MAX_NEG_CROP;
 
     ctx->has_palette = 0;
-    if ((ifo = fopen(p, "r")) == NULL) {
+    if ((ifo = avpriv_fopen_utf8(p, "r")) == NULL) {
         av_log(ctx, AV_LOG_WARNING, "Unable to open IFO file \"%s\": %s\n", p, av_err2str(AVERROR(errno)));
         return AVERROR_EOF;
     }
-- 
ffmpeg-codebot
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [FFmpeg-devel] [PATCH v7 0/2] use av_fopen_utf8() instead of plain fopen()
  2022-05-23 11:26           ` [FFmpeg-devel] [PATCH v7 0/2] use av_fopen_utf8() instead of plain fopen() ffmpegagent
  2022-05-23 11:26             ` [FFmpeg-devel] [PATCH v7 1/2] avfilter: " softworkz
  2022-05-23 11:26             ` [FFmpeg-devel] [PATCH v7 2/2] avcodec/dvdsubdec: " softworkz
@ 2022-05-24  8:55             ` Martin Storsjö
  2 siblings, 0 replies; 30+ messages in thread
From: Martin Storsjö @ 2022-05-24  8:55 UTC (permalink / raw)
  To: ffmpegagent; +Cc: Soft Works, Tobias Rapp, ffmpeg-devel

On Mon, 23 May 2022, ffmpegagent wrote:

> Unify file access operations by replacing usages of direct calls to posix
> fopen()
>
> v2: Remove changes to fftools for now
> v3: Add some additional replacements
> v4: Fix and improve commit messages
> v5: Add patch to remap ff_open in libavfilter for MSVC on Windows
> v6: Add avfilter/file_open.c to "Files without standard license headers"
> list
> v7: Rebase and use the new avpriv_fopen_utf8() instead
>
> softworkz (2):
>  avfilter: use av_fopen_utf8() instead of plain fopen()
>  avcodec/dvdsubdec: use av_fopen_utf8() instead of plain fopen()

Pushed, with the commit messages updated to use avpriv_fopen_utf8 too.

// Martin

_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

^ permalink raw reply	[flat|nested] 30+ messages in thread

end of thread, other threads:[~2022-05-24  8:55 UTC | newest]

Thread overview: 30+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-05-07 17:39 [FFmpeg-devel] [PATCH 0/2] use av_fopen_utf8() instead of plain fopen() ffmpegagent
2022-05-07 17:39 ` [FFmpeg-devel] [PATCH 1/2] fftools: " softworkz
2022-05-08 20:03   ` Martin Storsjö
2022-05-09  0:21     ` Soft Works
2022-05-07 17:39 ` [FFmpeg-devel] [PATCH 2/2] avfilter: " softworkz
2022-05-09 18:52 ` [FFmpeg-devel] [PATCH v2] " softworkz
2022-05-10 20:12   ` Martin Storsjö
2022-05-10 23:03     ` Soft Works
2022-05-17  0:39   ` [FFmpeg-devel] [PATCH v3 0/2] " ffmpegagent
2022-05-17  0:39     ` [FFmpeg-devel] [PATCH v3 1/2] avfilter: " softworkz
2022-05-17  0:39     ` [FFmpeg-devel] [PATCH v3 2/2] avfilter/dvdsubdec: " softworkz
2022-05-17 11:56     ` [FFmpeg-devel] [PATCH v3 0/2] " Tobias Rapp
2022-05-17 12:26       ` Soft Works
2022-05-17 12:29     ` [FFmpeg-devel] [PATCH v4 " ffmpegagent
2022-05-17 12:29       ` [FFmpeg-devel] [PATCH v4 1/2] avfilter: " softworkz
2022-05-17 12:29       ` [FFmpeg-devel] [PATCH v4 2/2] avcodec/dvdsubdec: " softworkz
2022-05-18  7:01       ` [FFmpeg-devel] [PATCH v4 0/2] " Tobias Rapp
2022-05-19 21:39         ` Soft Works
2022-05-19 21:40       ` [FFmpeg-devel] [PATCH v5 0/3] " ffmpegagent
2022-05-19 21:40         ` [FFmpeg-devel] [PATCH v5 1/3] avfilter: " softworkz
2022-05-19 21:40         ` [FFmpeg-devel] [PATCH v5 2/3] avcodec/dvdsubdec: " softworkz
2022-05-19 21:40         ` [FFmpeg-devel] [PATCH v5 3/3] avfilter: Make avpriv_open a library-internal function on msvcrt softworkz
2022-05-19 23:15         ` [FFmpeg-devel] [PATCH v6 0/3] use av_fopen_utf8() instead of plain fopen() ffmpegagent
2022-05-19 23:15           ` [FFmpeg-devel] [PATCH v6 1/3] avfilter: " softworkz
2022-05-19 23:15           ` [FFmpeg-devel] [PATCH v6 2/3] avcodec/dvdsubdec: " softworkz
2022-05-19 23:15           ` [FFmpeg-devel] [PATCH v6 3/3] avfilter: Make avpriv_open a library-internal function on msvcrt softworkz
2022-05-23 11:26           ` [FFmpeg-devel] [PATCH v7 0/2] use av_fopen_utf8() instead of plain fopen() ffmpegagent
2022-05-23 11:26             ` [FFmpeg-devel] [PATCH v7 1/2] avfilter: " softworkz
2022-05-23 11:26             ` [FFmpeg-devel] [PATCH v7 2/2] avcodec/dvdsubdec: " softworkz
2022-05-24  8:55             ` [FFmpeg-devel] [PATCH v7 0/2] " Martin Storsjö

Git Inbox Mirror of the ffmpeg-devel mailing list - see https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

This inbox may be cloned and mirrored by anyone:

	git clone --mirror https://master.gitmailbox.com/ffmpegdev/0 ffmpegdev/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 ffmpegdev ffmpegdev/ https://master.gitmailbox.com/ffmpegdev \
		ffmpegdev@gitmailbox.com
	public-inbox-index ffmpegdev

Example config snippet for mirrors.


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git