mirror of
https://github.com/termux-pacman/termux-packages.git
synced 2026-01-10 12:53:27 +00:00
vtm: Restore patch to fix alignment of data
as a follow-up of commit 8f2c1b0fe4918686dfdd1fc40ed0dcbabb54a632. Please always test on arm (32-bit) arch if you modify or delete it.
This commit is contained in:
@@ -4,6 +4,7 @@ TERMUX_PKG_LICENSE="MIT"
|
||||
TERMUX_PKG_LICENSE_FILE="../LICENSE"
|
||||
TERMUX_PKG_MAINTAINER="@termux"
|
||||
TERMUX_PKG_VERSION="0.9.8o"
|
||||
TERMUX_PKG_REVISION=1
|
||||
TERMUX_PKG_SRCURL=https://github.com/netxs-group/vtm/archive/refs/tags/v${TERMUX_PKG_VERSION}.tar.gz
|
||||
TERMUX_PKG_SHA256=f1a3e769c2de82bb14d56c490d2a9d3f15512e3b346244a3dcd93fc3ea22881e
|
||||
TERMUX_PKG_DEPENDS="libandroid-spawn, libc++"
|
||||
|
||||
17
packages/vtm/netxs-desktopio-directvt.hpp.patch
Normal file
17
packages/vtm/netxs-desktopio-directvt.hpp.patch
Normal file
@@ -0,0 +1,17 @@
|
||||
https://github.com/termux/termux-packages/issues/13594
|
||||
|
||||
Please always test on arm (32-bit) arch if you modify or delete this patch.
|
||||
|
||||
--- a/src/netxs/desktopio/directvt.hpp
|
||||
+++ b/src/netxs/desktopio/directvt.hpp
|
||||
@@ -182,7 +182,9 @@ namespace netxs::directvt
|
||||
log("dtvt: corrupted integer data");
|
||||
return D{};
|
||||
}
|
||||
- auto crop = netxs::letoh(*reinterpret_cast<D const*>(data.data()));
|
||||
+ auto data_aligned = D{};
|
||||
+ ::memcpy(&data_aligned, data.data(), sizeof(D));
|
||||
+ auto crop = netxs::letoh(data_aligned);
|
||||
if constexpr (!PeekOnly)
|
||||
{
|
||||
data.remove_prefix(sizeof(D));
|
||||
Reference in New Issue
Block a user