Skip to content

Commit

Permalink
Fix memcpy-param-overlap in patch for relocation
Browse files Browse the repository at this point in the history
Prefer memmove over memcpy for overlapping memory regions, otherwise it
triggers the address sanitizer with:

ERROR: AddressSanitizer: memcpy-param-overlap: memory ranges [x,y) and [a,b) overlap
  • Loading branch information
nehaljwani committed Jan 13, 2020
1 parent c9a432a commit 55de613
Show file tree
Hide file tree
Showing 29 changed files with 41 additions and 41 deletions.
2 changes: 1 addition & 1 deletion mingw-w64-curl/0001-Make-cURL-relocatable.patch
Original file line number Diff line number Diff line change
Expand Up @@ -331,7 +331,7 @@ index 000000000..c66df924b
+ for (i = 0; i < n_toks; ++i)
+ {
+ tok_size = strlen(toks[i]);
+ memcpy (result_p, toks[i], tok_size);
+ memmove (result_p, toks[i], tok_size);
+ result_p += tok_size;
+ if ((!i || tok_size) && ((i < n_toks - 1) || it_ended_with_a_slash == 1))
+ {
Expand Down
4 changes: 2 additions & 2 deletions mingw-w64-curl/PKGBUILD
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ _realname=curl
pkgbase=mingw-w64-${_realname}
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}${_namesuff}"
pkgver=7.68.0
pkgrel=1
pkgrel=2
pkgdesc="Command line tool and library for transferring data with URLs. (mingw-w64)"
arch=('any')
url="https://curl.haxx.se/"
Expand Down Expand Up @@ -48,7 +48,7 @@ source=("${url}/download/${_realname}-${pkgver}.tar.bz2"{,.asc}
"0003-libpsl-static-libs.patch")
sha256sums=('207f54917dd6a2dc733065ccf18d61bb5bebeaceb5df49cd9445483e8623eeb9'
'SKIP'
'b7fb18b1bd48e4e2df65dac0b7567cc5d0caa86ad3a1e9f7c21d36cc2db433b4'
'37dff8355e410b65563d51f7c1314d309276add644d55836a067142fc36951f4'
'79eec8a337e375d5102fef884030ceacd163a79e5c495e9a974a6b9a11b60c61'
'7492d019036b5bec251bfbc3c0b40e5f16d3dd6b2515068835e087a6c21f19ad')
validpgpkeys=('914C533DF9B2ADA2204F586D78E11C6B279D5C91' # Daniel Stenberg
Expand Down
2 changes: 1 addition & 1 deletion mingw-w64-cyrus-sasl/19-paths-relocation.patch
Original file line number Diff line number Diff line change
Expand Up @@ -385,7 +385,7 @@ diff -Naur cyrus-sasl-2.1.26-orig/lib/pathtools.c cyrus-sasl-2.1.26/lib/pathtool
+ for (i = 0; i < n_toks; ++i)
+ {
+ tok_size = strlen(toks[i]);
+ memcpy (result_p, toks[i], tok_size);
+ memmove (result_p, toks[i], tok_size);
+ result_p += tok_size;
+ if ((!i || tok_size) && ((i < n_toks - 1) || it_ended_with_a_slash == 1))
+ {
Expand Down
4 changes: 2 additions & 2 deletions mingw-w64-cyrus-sasl/PKGBUILD
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ pkgname=("${MINGW_PACKAGE_PREFIX}-${_realname}")
_rc=rc8
_basever=2.1.27
pkgver=${_basever}.${_rc}
pkgrel=1
pkgrel=2
pkgdesc="Cyrus Simple Authentication Service Layer (SASL) library"
arch=('any')
url="https://www.cyrusimap.org/sasl/"
Expand All @@ -53,7 +53,7 @@ sha256sums=('8d95201b4f2c2ec4c0ebafd01c00d7d1e0f2513352b3f850ae2723a90c6c6789'
'c7ad8c4e90e130b34ec66ff4056b9bd0ea98144f16552dc0a23387fc18a001b2'
'5b0104ec5fd190c7c6bd5b8d49c76e9c02609e449b499c0382cacd0e0f5032dd'
'd058e921d5b7b292371cff2e0334c067bfb8ce0ba85e82726b18961ae2e4f509'
'bd65e6b0705b5b7c81024435a386e6818aebc73e7681ceb4b8ca398f50661708')
'2823f70b1584d24cf9d4978ebcc1480087ed0764c342951a91563ef911878133')

prepare() {
cd ${srcdir}/${_realname}-${_basever}
Expand Down
4 changes: 2 additions & 2 deletions mingw-w64-firebird-git/PKGBUILD
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ _build_sys=autotools
pkgbase=mingw-w64-${_realname}-git
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}-git"
pkgver=3.0.0.31894.22cc629
pkgrel=1
pkgrel=2
pkgdesc="Cross-platform relational database offering many ANSI SQL standard features (mingw-w64)"
url="https://www.firebirdsql.org/"
license=('custom')
Expand Down Expand Up @@ -34,7 +34,7 @@ options=('!debug' 'strip')
source=("${_realname}"::"git+https://github.com/Alexpux/firebird-git-svn.git"
mingw-w64-trunk.patch)
sha256sums=('SKIP'
'7bb02ba92093a53ca6f2f7076d055922d0d8ac15694db7cdc154cc036dda941a')
'ccf5c85f487e2758f9d15e507e10fef238d3e262eef2ef328a73957d7b4000a4')


pkgver() {
Expand Down
2 changes: 1 addition & 1 deletion mingw-w64-firebird-git/mingw-w64-trunk.patch
Original file line number Diff line number Diff line change
Expand Up @@ -2534,7 +2534,7 @@ index 0000000..9291ffd
+ for (i = 0; i < n_toks; ++i)
+ {
+ tok_size = strlen(toks[i]);
+ memcpy (result_p, toks[i], tok_size);
+ memmove (result_p, toks[i], tok_size);
+ result_p += tok_size;
+ if ((!i || tok_size) && ((i < n_toks - 1) || it_ended_with_a_slash == 1))
+ {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -291,7 +291,7 @@ index 0000000000..9291ffd81f
+ for (i = 0; i < n_toks; ++i)
+ {
+ tok_size = strlen(toks[i]);
+ memcpy (result_p, toks[i], tok_size);
+ memmove (result_p, toks[i], tok_size);
+ result_p += tok_size;
+ if ((!i || tok_size) && ((i < n_toks - 1) || it_ended_with_a_slash == 1))
+ {
Expand Down
4 changes: 2 additions & 2 deletions mingw-w64-firebird2-git/PKGBUILD
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ _realname=firebird
pkgbase=mingw-w64-${_realname}2-git
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}2-git"
pkgver=2.5.9.27135.51a0964362
pkgrel=1
pkgrel=2
pkgdesc="Cross-platform relational database offering many ANSI SQL standard features - version 2.x (mingw-w64)"
url="https://www.firebirdsql.org/"
license=('custom')
Expand Down Expand Up @@ -195,7 +195,7 @@ sha256sums=('SKIP'
'e927670f2ef41cdb1f13f300308d75eb7de7b680c2e40246b65a0236fe8c2fad'
'865abc7226916fd4503a80ed5555a835d1774a4659fd32b49fdaa38e8f5d3353'
'5896a3a0b2732a9f835c183ea3d1269e1541428ce11c27b1f15fc3d683da8310'
'8a23055594e2bc3f4857f141417c8864ff02d533d94a3ede1cbbc5bdba68c158'
'ae6f499aaf99f80b32a91e21e7d51b6ec5569e88baa3828e54de1db0fb58fc27'
'32a3520e588f0cc6648dfdf66f5a2579ff67d4db30ecdaac69bcf275b8b8c919'
'2e2ee6f9c6d91a707b12666fa340c31b4f8edb8e910cd7ff08d6cfed5ed4c2d2'
'3dade981ceda60919b4ac4a64350855272ea60705ba58b984c15e6d3af3a18a8'
Expand Down
2 changes: 1 addition & 1 deletion mingw-w64-gnupg/05-mingw-relocation.patch
Original file line number Diff line number Diff line change
Expand Up @@ -305,7 +305,7 @@
+ for (i = 0; i < n_toks; ++i)
+ {
+ tok_size = strlen(toks[i]);
+ memcpy (result_p, toks[i], tok_size);
+ memmove (result_p, toks[i], tok_size);
+ result_p += tok_size;
+ if ((!i || tok_size) && ((i < n_toks - 1) || it_ended_with_a_slash == 1))
+ {
Expand Down
2 changes: 1 addition & 1 deletion mingw-w64-gnupg/PKGBUILD
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ _realname=gnupg
pkgbase=mingw-w64-${_realname}
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
pkgver=2.2.19
pkgrel=1
pkgrel=2
pkgdesc="GNU Privacy Guard - a PGP replacement tool (mingw-w64)"
arch=('any')
depends=("${MINGW_PACKAGE_PREFIX}-adns"
Expand Down
2 changes: 1 addition & 1 deletion mingw-w64-graphicsmagick/001-relocate.patch
Original file line number Diff line number Diff line change
Expand Up @@ -423,7 +423,7 @@ diff -Naur GraphicsMagick-1.3.20-orig/magick/pathtools.c GraphicsMagick-1.3.20/m
+ for (i = 0; i < n_toks; ++i)
+ {
+ tok_size = strlen(toks[i]);
+ memcpy (result_p, toks[i], tok_size);
+ memmove (result_p, toks[i], tok_size);
+ result_p += tok_size;
+ if ((!i || tok_size) && ((i < n_toks - 1) || it_ended_with_a_slash == 1))
+ {
Expand Down
4 changes: 2 additions & 2 deletions mingw-w64-graphicsmagick/PKGBUILD
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ _realname=graphicsmagick
pkgbase=mingw-w64-${_realname}
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
pkgver=1.3.33
pkgrel=1
pkgrel=2
pkgdesc="An image viewing/manipulation program (mingw-w64)"
arch=('any')
url="http://www.graphicsmagick.org/"
Expand Down Expand Up @@ -37,7 +37,7 @@ options=('staticlibs' 'strip' 'libtool')
source=(https://sourceforge.net/projects/graphicsmagick/files/${_realname}/${pkgver}/GraphicsMagick-${pkgver}.tar.xz
001-relocate.patch)
sha256sums=('130cb330a633580b5124eba5c125bbcbc484298423a97b9bed37ccd50d6dc778'
'd960ba9ebb98acc922794315913e743938fb0b903aa3ab0652eb653e2641b232')
'704f98f75d0f9ff87b4ecf61758b084f83d83ebb5de35917de4c26eb215b704b')

# Helper macros to help make tasks easier #
apply_patch_with_msg() {
Expand Down
2 changes: 1 addition & 1 deletion mingw-w64-hunspell/01-relocate.patch
Original file line number Diff line number Diff line change
Expand Up @@ -355,7 +355,7 @@ index 0000000..d8ba8cf
+ for (i = 0; i < n_toks; ++i)
+ {
+ tok_size = strlen(toks[i]);
+ memcpy (result_p, toks[i], tok_size);
+ memmove (result_p, toks[i], tok_size);
+ result_p += tok_size;
+ if ((!i || tok_size) && ((i < n_toks - 1) || it_ended_with_a_slash == 1))
+ {
Expand Down
4 changes: 2 additions & 2 deletions mingw-w64-hunspell/PKGBUILD
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
# Please rebuild enchant when updating this if needed, otherwise it may
# silently break spell checking in applications
pkgver=1.7.0
pkgrel=4
pkgrel=5
pkgdesc="Spell checker and morphological analyzer library and program (mingw-w64)"
arch=('any')
url="https://hunspell.github.io/"
Expand All @@ -28,7 +28,7 @@ source=("${_realname}-${pkgver}.tar.gz"::"https://github.com/hunspell/hunspell/a
02-fix-link-with-pdcurses.patch)
noextract=("${_realname}-${pkgver}.tar.gz")
sha256sums=('bb27b86eb910a8285407cf3ca33b62643a02798cf2eef468c0a74f6c3ee6bc8a'
'b3a978749ef723481286e6237944729b6965bc57eacc5407b5f7fedf7d6aa8a1'
'abb8bff7367a80bd3cc4237c118ba2beb3d9ecf446a40a1c5d9990166bfb92fc'
'260432a8f01525e83124c79e375cc9f0692b1a6c97773add4c69b8efe081cf1d')

prepare() {
Expand Down
2 changes: 1 addition & 1 deletion mingw-w64-imagemagick/001-7.0.4.1-relocate.patch
Original file line number Diff line number Diff line change
Expand Up @@ -399,7 +399,7 @@ diff -Naur ImageMagick-7.0.1-3-orig/MagickCore/pathtools.c ImageMagick-6.8.9-8/m
+ for (i = 0; i < n_toks; ++i)
+ {
+ tok_size = strlen(toks[i]);
+ memcpy (result_p, toks[i], tok_size);
+ memmove (result_p, toks[i], tok_size);
+ result_p += tok_size;
+ if ((!i || tok_size) && ((i < n_toks - 1) || it_ended_with_a_slash == 1))
+ {
Expand Down
2 changes: 1 addition & 1 deletion mingw-w64-imagemagick/PKGBUILD
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
_basever=7.0.9
_rc=-2
pkgver=${_basever}${_rc//-/.}
pkgrel=1
pkgrel=2
pkgdesc="An image viewing/manipulation program (mingw-w64)"
arch=('any')
url="https://www.imagemagick.org/"
Expand Down
4 changes: 2 additions & 2 deletions mingw-w64-ldns/PKGBUILD
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ _realname=ldns
pkgbase=mingw-w64-${_realname}
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
pkgver=1.7.0
pkgrel=3
pkgrel=4
pkgdesc="Fast DNS library supporting recent RFCs (mingw-w64)"
arch=('any')
url='https://www.nlnetlabs.nl/projects/ldns/'
Expand All @@ -19,7 +19,7 @@ source=("https://www.nlnetlabs.nl/downloads/${_realname}/${_realname}-${pkgver}.
ldns-1.6.17-relocate.patch)
sha256sums=('c19f5b1b4fb374cfe34f4845ea11b1e0551ddc67803bd6ddd5d2a20f0997a6cc'
'SKIP'
'3b28f06db2dff69613c7a9776fa444988a5238096952459a7d01eaae1d7ab948')
'29728dac1131c0605e2742d40c7d6165d3c90558bab1b699b08408d38b669a33')

prepare() {
cd ${srcdir}/${_realname}-${pkgver}
Expand Down
2 changes: 1 addition & 1 deletion mingw-w64-ldns/ldns-1.6.17-relocate.patch
Original file line number Diff line number Diff line change
Expand Up @@ -354,7 +354,7 @@ diff -Naur ldns-1.6.17-orig/pathtools.c ldns-1.6.17/pathtools.c
+ for (i = 0; i < n_toks; ++i)
+ {
+ tok_size = strlen(toks[i]);
+ memcpy (result_p, toks[i], tok_size);
+ memmove (result_p, toks[i], tok_size);
+ result_p += tok_size;
+ if ((!i || tok_size) && ((i < n_toks - 1) || it_ended_with_a_slash == 1))
+ {
Expand Down
2 changes: 1 addition & 1 deletion mingw-w64-libxml2/0026-mingw-relocate.patch
Original file line number Diff line number Diff line change
Expand Up @@ -327,7 +327,7 @@ diff -Naur '--exclude=.vscode' '--exclude=autom4te.cache' '--exclude=*.in' libxm
+ for (i = 0; i < n_toks; ++i)
+ {
+ tok_size = strlen(toks[i]);
+ memcpy (result_p, toks[i], tok_size);
+ memmove (result_p, toks[i], tok_size);
+ result_p += tok_size;
+ if ((!i || tok_size) && ((i < n_toks - 1) || it_ended_with_a_slash == 1))
+ {
Expand Down
4 changes: 2 additions & 2 deletions mingw-w64-libxml2/PKGBUILD
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ _realname=libxml2
pkgbase=mingw-w64-${_realname}
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
pkgver=2.9.10
pkgrel=2
pkgrel=3
arch=('any')
pkgdesc="XML parsing library, version 2 (mingw-w64)"
depends=("${MINGW_PACKAGE_PREFIX}-gcc-libs"
Expand Down Expand Up @@ -36,7 +36,7 @@ sha256sums=('aafee193ffb8fe0c82d4afef6ef91972cbaf5feea100edc2f262750611b4be1f'
'3f025f34bf0c9b084905d24a7195315bccba45a617a02cd051cd5ee791fad098'
'4e8377b8bd163cc29056e45f59598e36dc6f00029166bdce4c78a88f1f9b3ed4'
'e93902af20bee41ca7708280f30a1d087ab8c6f86d18939bdd56789cd1a73531'
'b66fcd4feccf6995289353d78f967be598928e66a8bc6fa910bf331402c53dc0'
'185033761dbfa2ff206df2adf87abb79d4733b5c84a6c68c429872a0755818d9'
'7b9bc59b174da93a547429b2f751047c758657953f6e2fb398e73b5ebf0f55e3')

# Helper macros to help make tasks easier #
Expand Down
4 changes: 2 additions & 2 deletions mingw-w64-openssl/PKGBUILD
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ pkgname=("${MINGW_PACKAGE_PREFIX}-${_realname}")
_ver=1.1.1d
# use a pacman compatible version scheme
pkgver=${_ver/[a-z]/.${_ver//[0-9.]/}}
pkgrel=1
pkgrel=2
arch=('any')
pkgdesc="The Open Source toolkit for Secure Sockets Layer and Transport Layer Security (mingw-w64)"
depends=("${MINGW_PACKAGE_PREFIX}-ca-certificates" "${MINGW_PACKAGE_PREFIX}-gcc-libs" "${MINGW_PACKAGE_PREFIX}-zlib")
Expand All @@ -19,7 +19,7 @@ source=(https://www.openssl.org/source/${_realname}-${_ver}.tar.gz{,.asc}
'openssl-1.1.1-relocation.patch')
sha256sums=('1e3a91bc1f9dfce01af26026f856e064eab4c8ee0a8f457b5ae30b40b8b711f2'
'SKIP'
'5e1d04163a525861972f0c45ff37f2c219ebf657544bb7481faf08453b91640b')
'cb342c73fdaedf9971c3a5ee1405ae33d823fe0c3c66a73e5515caceda428208')

validpgpkeys=('8657ABB260F056B1E5190839D9C4D26D0E604491'
'7953AC1FBC3DC8B3B292393ED5E9E43F7DF9EE8C')
Expand Down
2 changes: 1 addition & 1 deletion mingw-w64-openssl/openssl-1.1.1-relocation.patch
Original file line number Diff line number Diff line change
Expand Up @@ -311,7 +311,7 @@ index 0000000000..81ffa7e8a6
+ for (i = 0; i < n_toks; ++i)
+ {
+ tok_size = strlen(toks[i]);
+ memcpy (result_p, toks[i], tok_size);
+ memmove (result_p, toks[i], tok_size);
+ result_p += tok_size;
+ if ((!i || tok_size) && ((i < n_toks - 1) || it_ended_with_a_slash == 1))
+ {
Expand Down
2 changes: 1 addition & 1 deletion mingw-w64-p11-kit/0006-p11-kit-relocation.patch
Original file line number Diff line number Diff line change
Expand Up @@ -326,7 +326,7 @@ diff -Naur p11-kit-0.20.3-orig/common/pathtools.c p11-kit-0.20.3/common/pathtool
+ for (i = 0; i < n_toks; ++i)
+ {
+ tok_size = strlen(toks[i]);
+ memcpy (result_p, toks[i], tok_size);
+ memmove (result_p, toks[i], tok_size);
+ result_p += tok_size;
+ if ((!i || tok_size) && ((i < n_toks - 1) || it_ended_with_a_slash == 1))
+ {
Expand Down
4 changes: 2 additions & 2 deletions mingw-w64-p11-kit/PKGBUILD
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ _realname=p11-kit
pkgbase=mingw-w64-${_realname}
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
pkgver=0.23.18.1
pkgrel=1
pkgrel=2
pkgdesc="Library to work with PKCS#11 modules"
arch=('any')
url="https://p11-glue.freedesktop.org/p11-kit.html"
Expand Down Expand Up @@ -34,7 +34,7 @@ sha256sums=('34c3bd8c0050dd7c4e6228aecf0f168de0a1b34562ddbf74a1c70904c2523c6f'
'195b2e8695f701caf545e2a468383ad29457febd9b1ee57de1986de04ad3c31c'
'aa92f986d3f7dfc119e86f9a8f3987e6ac2562149921820eadbe09218c4df99c'
'ea4593324db6d2d193733561f0352c6d679d1fb00aed0a2bae0d28aecbe92721'
'b63184b26c8c97f9112bf56d63b0f5096cece26221bbe14f9b480502a9963466'
'14d39c061d947c40a3354fbfc2a126d6d025ce78ed8fb1d68f36c15ad01a0621'
'2b0fc5c54776aca54e306315338323075e7412d8d800f490a31870008c34f8d1'
'652e4be637bf77f20d8fde91175286701430e720e4082e8818a50ebddff28460'
'8c796ade0ef6356c796d2e87b967c7a9d888783c08e740e35d5686f6deb7f009'
Expand Down
2 changes: 1 addition & 1 deletion mingw-w64-pathtools/pathtools.c
Original file line number Diff line number Diff line change
Expand Up @@ -246,7 +246,7 @@ simplify_path(char * path)
for (i = 0; i < n_toks; ++i)
{
tok_size = strlen(toks[i]);
memcpy (result_p, toks[i], tok_size);
memmove (result_p, toks[i], tok_size);
result_p += tok_size;
if ((!i || tok_size) && ((i < n_toks - 1) || it_ended_with_a_slash == 1))
{
Expand Down
4 changes: 2 additions & 2 deletions mingw-w64-port-scanner/PKGBUILD
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ _realname=port-scanner
pkgbase=mingw-w64-${_realname}
pkgname=("${MINGW_PACKAGE_PREFIX}-${_realname}")
pkgver=1.3
pkgrel=2
pkgrel=3
pkgdesc="A multi threaded TCP port scanner from SecPoint.com (mingw-w64)"
arch=('any')
url="https://www.secpoint.com/multi-threaded-tcp-port-scanner.html"
Expand All @@ -13,7 +13,7 @@ makedepends=("${MINGW_PACKAGE_PREFIX}-gcc")
source=("https://www.secpoint.com/freetools/threaded-port-scanner-${pkgver}.zip"
"paths.patch")
sha256sums=('768c595fba7ba7e81da35e1bba1118bf08a1d689c6e419804d2109fc64177436'
'7ff276ca6c8195d22f6e84df4d4e83fa29f93b93cf15d88c3a4a790cdb202496')
'71d17400c3c00387d7f5ba9b0bfa761b29c3707cf0ff1708c4e1b496686d32e9')

prepare() {
cd "${srcdir}/threaded-port-scanner-${pkgver}"
Expand Down
2 changes: 1 addition & 1 deletion mingw-w64-port-scanner/paths.patch
Original file line number Diff line number Diff line change
Expand Up @@ -380,7 +380,7 @@ diff -Naur orig/pathtools.c threaded-port-scanner-1.3/pathtools.c
+ for (i = 0; i < n_toks; ++i)
+ {
+ tok_size = strlen(toks[i]);
+ memcpy (result_p, toks[i], tok_size);
+ memmove (result_p, toks[i], tok_size);
+ result_p += tok_size;
+ if ((!i || tok_size) && ((i < n_toks - 1) || it_ended_with_a_slash == 1))
+ {
Expand Down
2 changes: 1 addition & 1 deletion mingw-w64-swig/001-relocate.patch
Original file line number Diff line number Diff line change
Expand Up @@ -320,7 +320,7 @@ diff -Naur swig-4.0.0.orig/Source/Swig/pathtools.c swig-4.0.0/Source/Swig/pathto
+ for (i = 0; i < n_toks; ++i)
+ {
+ tok_size = strlen(toks[i]);
+ memcpy (result_p, toks[i], tok_size);
+ memmove (result_p, toks[i], tok_size);
+ result_p += tok_size;
+ if ((!i || tok_size) && ((i < n_toks - 1) || it_ended_with_a_slash == 1))
+ {
Expand Down
4 changes: 2 additions & 2 deletions mingw-w64-swig/PKGBUILD
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ _realname=swig
pkgbase=mingw-w64-${_realname}
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
pkgver=4.0.1
pkgrel=2
pkgrel=3
pkgdesc="Generate scripting interfaces to C/C++ code (mingw-w64)"
arch=('any')
url="http://www.swig.org/"
Expand All @@ -19,7 +19,7 @@ source=(https://downloads.sourceforge.net/${_realname}/${_realname}-${pkgver}.ta
001-relocate.patch
002-fix-python-find.patch)
sha256sums=('7a00b4d0d53ad97a14316135e2d702091cd5f193bb58bcfcd8bc59d41e7887a9'
'89ebd0d68f13eb9889e995329d8e686b1ac8c66c65a08631231fede6a3400656'
'cf76da65d87738b68dbc633aa871f1fb3cb742db1fb603c8a37de2ccbef2b8bb'
'057f0a306aee0d28a5bb6538b569c650e47c05b9848c9477cdeb7bb8c792944d')

prepare() {
Expand Down

0 comments on commit 55de613

Please sign in to comment.