diff options
author | atomlong | 2021-09-11 17:57:19 +0800 |
---|---|---|
committer | atomlong | 2021-09-11 17:57:31 +0800 |
commit | 3cfcc5a847991b1143bc4f09d2fb6c2cac27885d (patch) | |
tree | a09fd7800e58c7b76223460d3b7e02cb030dfb66 | |
parent | 040c841a729397a3b25af959dc38d19e4e7212bc (diff) | |
download | aur-3cfcc5a847991b1143bc4f09d2fb6c2cac27885d.tar.gz |
fix format security error
fix error:
../../src/bs2bconvert.c:156:17: error: format not a string literal and no format arguments [-Werror=format-security]
156 | printf( sf_strerror( NULL ) );
| ^~~~~~
cc1: some warnings being treated as errors
make[1]: *** [Makefile:547: bs2bconvert.o] Error 1
-rw-r--r-- | .SRCINFO | 4 | ||||
-rw-r--r-- | PKGBUILD | 10 | ||||
-rw-r--r-- | fix-format-security-error.patch | 12 |
3 files changed, 22 insertions, 4 deletions
@@ -12,10 +12,12 @@ pkgbase = mingw-w64-libbs2b options = staticlibs source = https://downloads.sourceforge.net/sourceforge/bs2b/libbs2b-3.1.0.tar.gz source = fix-dll-no-undefined.patch + source = fix-format-security-error.patch md5sums = 2c3351f1785364107aabc44f67d33d84 md5sums = 032add726f4355682a09b34fcb610328 + md5sums = 6158826339a7082348195eaa0c205756 sha1sums = a71318211611a00bd3d595b0830d2188938ff89d sha1sums = a8f643592e2851e25dda19ecf33f39f5132668a1 + sha1sums = 8c6ea1d38789107cc9b1a71dd5eb24864ad50341 pkgname = mingw-w64-libbs2b - @@ -12,17 +12,21 @@ depends=('mingw-w64-libsndfile') makedepends=('mingw-w64-configure') options=('!strip' '!buildflags' 'staticlibs') source=("https://downloads.sourceforge.net/sourceforge/bs2b/${_pkgname}-${pkgver}.tar.gz" - "fix-dll-no-undefined.patch") + "fix-dll-no-undefined.patch" + "fix-format-security-error.patch") md5sums=('2c3351f1785364107aabc44f67d33d84' - '032add726f4355682a09b34fcb610328') + '032add726f4355682a09b34fcb610328' + '6158826339a7082348195eaa0c205756') sha1sums=('a71318211611a00bd3d595b0830d2188938ff89d' - 'a8f643592e2851e25dda19ecf33f39f5132668a1') + 'a8f643592e2851e25dda19ecf33f39f5132668a1' + '8c6ea1d38789107cc9b1a71dd5eb24864ad50341') _architectures="i686-w64-mingw32 x86_64-w64-mingw32" prepare() { cd "${srcdir}/${_pkgname}-${pkgver}" patch -Np1 -i "${srcdir}/fix-dll-no-undefined.patch" + patch -Np1 -i "${srcdir}/fix-format-security-error.patch" autoreconf -fiv } diff --git a/fix-format-security-error.patch b/fix-format-security-error.patch new file mode 100644 index 000000000000..2909e045c35d --- /dev/null +++ b/fix-format-security-error.patch @@ -0,0 +1,12 @@ +diff -durN libbs2b-3.1.0.orig/src/bs2bconvert.c libbs2b-3.1.0/src/bs2bconvert.c +--- libbs2b-3.1.0.orig/src/bs2bconvert.c 2009-06-05 02:01:15.000000000 +0800 ++++ libbs2b-3.1.0/src/bs2bconvert.c 2021-09-11 17:53:23.535750900 +0800 +@@ -153,7 +153,7 @@ + if( ( infile = sf_open( infilename, SFM_READ, &sfinfo ) ) == NULL ) + { + printf( "Not able to open input file %s.\n", infilename ); +- printf( sf_strerror( NULL ) ); ++ printf( "%s", sf_strerror( NULL ) ); + return 1; + } + |