From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org [79.124.17.100]) by master.gitmailbox.com (Postfix) with ESMTP id 03C9A40416 for ; Fri, 25 Mar 2022 17:26:27 +0000 (UTC) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 49C5168B0FD; Fri, 25 Mar 2022 19:26:25 +0200 (EET) Received: from relay5-d.mail.gandi.net (relay5-d.mail.gandi.net [217.70.183.197]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 901B068AE8D for ; Fri, 25 Mar 2022 19:26:19 +0200 (EET) Received: from localhost (213-47-68-29.cable.dynamic.surfer.at [213.47.68.29]) (Authenticated sender: michael@niedermayer.cc) by mail.gandi.net (Postfix) with ESMTPSA id DE6241C0007 for ; Fri, 25 Mar 2022 17:26:18 +0000 (UTC) Date: Fri, 25 Mar 2022 18:26:17 +0100 From: Michael Niedermayer To: FFmpeg development discussions and patches Message-ID: <20220325172617.GX2829255@pb2> References: <20220325141041.1748-1-dcnieho@gmail.com> <20220325141041.1748-21-dcnieho@gmail.com> MIME-Version: 1.0 In-Reply-To: <20220325141041.1748-21-dcnieho@gmail.com> Subject: Re: [FFmpeg-devel] [PATCH v4 20/22] doc/examples: adding device_get_capabilities example X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Content-Type: multipart/mixed; boundary="===============0920930270473481282==" Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" Archived-At: List-Archive: List-Post: --===============0920930270473481282== Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="W3Lke5DiW5ogn24s" Content-Disposition: inline --W3Lke5DiW5ogn24s Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Fri, Mar 25, 2022 at 03:10:39PM +0100, Diederick Niehorster wrote: > This example also shows use of get_device_list API. >=20 > Also improve capability API doc in avdevice.h: now point to this example > instead of rough example code given in the header. >=20 > Signed-off-by: Diederick Niehorster > --- > configure | 2 + > doc/examples/.gitignore | 1 + > doc/examples/Makefile | 1 + > doc/examples/Makefile.example | 1 + > doc/examples/device_get_capabilities.c | 243 +++++++++++++++++++++++++ > libavdevice/avdevice.h | 33 +--- > 6 files changed, 249 insertions(+), 32 deletions(-) > create mode 100644 doc/examples/device_get_capabilities.c maybe i forgot something but this seems not building make examples -j32 CC doc/examples/device_get_capabilities.o In file included from ./libavformat/avformat.h:330:0, from doc/examples/device_get_capabilities.c:33: =2E/libavformat/version.h:55:1: warning: function declaration isn=E2=80=99t= a prototype [-Wstrict-prototypes] unsigned avformat_version_same_minor(); ^~~~~~~~ In file included from ./libavdevice/avdevice.h:27:0, from doc/examples/device_get_capabilities.c:34: =2E/libavdevice/version.h:54:1: warning: function declaration isn=E2=80=99t= a prototype [-Wstrict-prototypes] unsigned avdevice_version_same_minor(); ^~~~~~~~ doc/examples/device_get_capabilities.c:39:5: error: no previous prototype f= or =E2=80=98print_option_ranges=E2=80=99 [-Werror=3Dmissing-prototypes] int print_option_ranges(enum AVOptionType type, AVOptionRanges *ranges) ^~~~~~~~~~~~~~~~~~~ doc/examples/device_get_capabilities.c:73:6: warning: function declaration = isn=E2=80=99t a prototype [-Wstrict-prototypes] void list_queries() ^~~~~~~~~~~~ doc/examples/device_get_capabilities.c:81:6: error: no previous prototype f= or =E2=80=98list_device_sources=E2=80=99 [-Werror=3Dmissing-prototypes] void list_device_sources(const AVInputFormat *fmt) ^~~~~~~~~~~~~~~~~~~ cc1: some warnings being treated as errors ffbuild/common.mak:78: recipe for target 'doc/examples/device_get_capabilit= ies.o' failed make: *** [doc/examples/device_get_capabilities.o] Error 1 make: *** Waiting for unfinished jobs.... [...] --=20 Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB Its not that you shouldnt use gotos but rather that you should write readable code and code with gotos often but not always is less readable --W3Lke5DiW5ogn24s Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iF0EABEIAB0WIQSf8hKLFH72cwut8TNhHseHBAsPqwUCYj37MgAKCRBhHseHBAsP q1KsAJ9dIUU/SYu/gXc5Y2vUOvauVBhTBACeNus140zxHBwORTlpE83FEuFJp5c= =7J3A -----END PGP SIGNATURE----- --W3Lke5DiW5ogn24s-- --===============0920930270473481282== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ 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". --===============0920930270473481282==--