head 1.1; access; symbols pkgsrc-2026Q1:1.1.0.16 pkgsrc-2026Q1-base:1.1 pkgsrc-2025Q4:1.1.0.14 pkgsrc-2025Q4-base:1.1 pkgsrc-2025Q3:1.1.0.12 pkgsrc-2025Q3-base:1.1 pkgsrc-2025Q2:1.1.0.10 pkgsrc-2025Q2-base:1.1 pkgsrc-2025Q1:1.1.0.8 pkgsrc-2025Q1-base:1.1 pkgsrc-2024Q4:1.1.0.6 pkgsrc-2024Q4-base:1.1 pkgsrc-2024Q3:1.1.0.4 pkgsrc-2024Q3-base:1.1 pkgsrc-2024Q2:1.1.0.2 pkgsrc-2024Q2-base:1.1; locks; strict; comment @// @; 1.1 date 2024.04.07.04.24.23; author pho; state Exp; branches; next ; commitid PYb4Z3SLBHEqna5F; desc @@ 1.1 log @inputmethod/uim: Fix build on NetBSD 10 @ text @$NetBSD$ Don't use alloca(3). It's non-standard and is easily avoidable these days. TODO: Upstream this. --- xim/connection.cpp.orig 2024-04-07 04:05:48.893877145 +0000 +++ xim/connection.cpp @@@@ -45,9 +45,6 @@@@ #include #include #include -#ifdef HAVE_ALLOCA_H -# include -#endif #define INIT_BUF_SIZE 1024 #define TRANSPORT_UNIT 20 @@@@ -436,10 +433,9 @@@@ void XConnection::doSend(TxPacket *t, bo XClientMessageEvent r; int buflen; - char *buf; buflen = t->get_length(); - buf = (char *)alloca(buflen); + char buf[buflen]; t->write_to_buf((unsigned char *)buf, buflen, mByteorder); if (buflen < TRANSPORT_MAX) { // via event @