Opened 5 years ago

Closed 5 years ago

#999 closed defect (fixed)

error: 'wcscpy_instead_use_StringCbCopyW_or_StringCchCopyW' undeclared (first use in this function)

Reported by: KSHawkEye Owned by:
Priority: critical Component: avdevice
Version: 0.10 Keywords:
Cc: Blocked By:
Blocking: Reproduced by developer: no
Analyzed by developer: no


When trying to compile FFmpeg 0.10 with MinGW-w64 I get this error:

i686-w64-mingw32-gcc -I. -I/home/kyle/software/ffmpeg/source/ffmpeg-0.10/ -D_ISOC99_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -U__STRICT_ANSI__ -DHAVE_AV_CONFIG_H -std=c99 -fno-common -fomit-frame-pointer -g -Wdeclaration-after-statement -Wall -Wno-parentheses -Wno-switch -Wno-format-zero-length -Wdisabled-optimization -Wpointer-arith -Wredundant-decls -Wno-pointer-sign -Wcast-qual -Wwrite-strings -Wtype-limits -Wundef -Wmissing-prototypes -Wno-pointer-to-int-cast -Wstrict-prototypes -O3 -fno-math-errno -fno-signed-zeros -fno-tree-vectorize -Werror=implicit-function-declaration -Werror=missing-prototypes  -MMD -MF libavdevice/dshow_filter.d -MT libavdevice/dshow_filter.o -c -o libavdevice/dshow_filter.o /home/kyle/software/ffmpeg/source/ffmpeg-0.10/libavdevice/dshow_filter.c
/home/kyle/software/ffmpeg/source/ffmpeg-0.10/libavdevice/dshow_filter.c: In function 'libAVFilter_JoinFilterGraph':
/home/kyle/software/ffmpeg/source/ffmpeg-0.10/libavdevice/dshow_filter.c:149:9: error: 'wcscpy_instead_use_StringCbCopyW_or_StringCchCopyW' undeclared (first use in this function)
/home/kyle/software/ffmpeg/source/ffmpeg-0.10/libavdevice/dshow_filter.c:149:9: note: each undeclared identifier is reported only once for each function it appears in
/home/kyle/software/ffmpeg/source/ffmpeg-0.10/libavdevice/dshow_filter.c:149:34: warning: left-hand operand of comma expression has no effect [-Wunused-value]
/home/kyle/software/ffmpeg/source/ffmpeg-0.10/libavdevice/dshow_filter.c:149:15: warning: statement with no effect [-Wunused-value]
make: *** [libavdevice/dshow_filter.o] Error 1

Any ideas?

Change History (5)

comment:1 Changed 5 years ago by funman

You should apply the fix made in;a=commitdiff;h=bb7509af051d8384b9266bcdb345c553f608559c#patch1

Using the secure versions would be better but doesn't have them afaik.

comment:2 Changed 5 years ago by funman

Oops the important part is the 2nd diff: NO_DSHOW_STRSAFE

comment:3 Changed 5 years ago by michael

if someone send me a patch or confirm that some change fixes it then ill apply it

Last edited 5 years ago by michael (previous) (diff)

comment:4 Changed 5 years ago by funman

From 91e66b9e710d164703c30d5752a3e7ee0e556a3a Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Rafa=C3=ABl=20Carr=C3=A9?= <>
Date: Thu, 16 Feb 2012 17:15:59 -0500
Subject: [PATCH] dshow_filter: fix compilation with mingw-w64

Closes ticket #999
NO_DSHOW_STRSAFE asks dshow.h header to not use secure string function
Using secure replacements would break compatibility as they don't
declare/define those functions.
 libavdevice/dshow_filter.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/libavdevice/dshow_filter.c b/libavdevice/dshow_filter.c
index 64e8306..526e8b6 100644
--- a/libavdevice/dshow_filter.c
+++ b/libavdevice/dshow_filter.c
@@ -19,6 +19,7 @@
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
 #include "dshow.h"
Version 0, edited 5 years ago by funman (next)

comment:5 Changed 5 years ago by michael

  • Resolution set to fixed
  • Status changed from new to closed

Patch applied

Note: See TracTickets for help on using tickets.