Package: ucspi-tcp Followup-For: Bug #1066629 User: ubuntu-de...@lists.ubuntu.com Usertags: origin-ubuntu noble ubuntu-patch Control: tags -1 patch
Dear Maintainer, In Ubuntu, the attached patch was applied to achieve the following: * debian/patches/0006-implicit-declarations.patch: Add missing includes and prototypes. Closes LP: #2061188. * debian/ipv6-support.patch: Refresh deferred patch. Thanks for considering the patch. -- System Information: Debian Release: bookworm/sid APT prefers jammy-updates APT policy: (500, 'jammy-updates'), (500, 'jammy-security'), (500, 'jammy'), (100, 'jammy-backports') Architecture: amd64 (x86_64) Foreign Architectures: i386 Kernel: Linux 6.5.0-26-generic (SMP w/10 CPU threads; PREEMPT) Kernel taint flags: TAINT_PROPRIETARY_MODULE, TAINT_OOT_MODULE Locale: LANG=en_CA.UTF-8, LC_CTYPE=en_CA.UTF-8 (charmap=UTF-8), LANGUAGE=en_CA:en Shell: /bin/sh linked to /usr/bin/dash Init: systemd (via /run/systemd/system) LSM: AppArmor: enabled
diff -Nru ucspi-tcp-0.88/debian/ipv6-support.patch ucspi-tcp-0.88/debian/ipv6-support.patch --- ucspi-tcp-0.88/debian/ipv6-support.patch 2024-02-27 02:57:42.000000000 -0700 +++ ucspi-tcp-0.88/debian/ipv6-support.patch 2024-04-12 14:19:46.000000000 -0600 @@ -741,7 +741,7 @@ index 0948b1a..f06c5a8 100644 --- a/dns.h +++ b/dns.h -@@ -34,51 +34,60 @@ struct dns_transmit { +@@ -34,51 +34,61 @@ struct dns_transmit { unsigned int curserver; struct taia deadline; unsigned int pos; @@ -812,6 +812,7 @@ -extern int dns_mx_packet(stralloc *,char *,unsigned int); -extern int dns_mx(stralloc *,stralloc *); +extern int dns_name4(stralloc *,const char *); ++extern int dns_name6(stralloc *,char *); +extern int dns_txt_packet(stralloc *,const char *,unsigned int); +extern int dns_txt(stralloc *,const stralloc *); +extern int dns_mx_packet(stralloc *,const char *,unsigned int); @@ -1330,11 +1331,6 @@ index b9892b4..2158ed4 100644 --- a/dns_random.c +++ b/dns_random.c -@@ -1,3 +1,4 @@ -+#include <unistd.h> - #include "dns.h" - #include "taia.h" - #include "uint32.h" @@ -29,7 +30,7 @@ static void surf(void) } } @@ -1433,8 +1429,8 @@ index 6f215ac..b0c8e6d 100644 --- a/dns_rcrw.c +++ b/dns_rcrw.c -@@ -1,16 +1,17 @@ -+#include <unistd.h> +@@ -1,16 +1,16 @@ + #include <unistd.h> #include "taia.h" -#include "env.h" #include "byte.h" @@ -1511,17 +1507,7 @@ index df12826..9511511 100644 --- a/dns_transmit.c +++ b/dns_transmit.c -@@ -1,12 +1,15 @@ -+#include <sys/types.h> -+#include <sys/socket.h> -+#include <unistd.h> -+#include <stdlib.h> - #include "socket.h" --#include "alloc.h" --#include "error.h" -+#include <errno.h> - #include "byte.h" --#include "readwrite.h" +@@ -7,7 +7,8 @@ #include "uint16.h" #include "dns.h" +#include "ip6.h" @@ -1985,7 +1971,7 @@ +#include "byte.h" + +extern unsigned int scan_ip6(const char *src,char *ip); -+extern unsigned int fmt_ip6(char *dest,const char *ip); ++extern unsigned int ip6_fmt(char *dest,char *ip); + +extern unsigned int scan_ip6_flat(const char *src,char *); +extern unsigned int fmt_ip6_flat(char *dest,const char *); @@ -2357,7 +2343,8 @@ index 0000000..cf3b7c1 --- /dev/null +++ b/remoteinfo6.c -@@ -0,0 +1,98 @@ +@@ -0,0 +1,99 @@ ++#include <unistd.h> +#include "fmt.h" +#include "buffer.h" +#include "socket.h" @@ -3065,7 +3052,8 @@ index 0000000..74099e2 --- /dev/null +++ b/socket_tcp6.c -@@ -0,0 +1,44 @@ +@@ -0,0 +1,45 @@ ++#include <unistd.h> +#include <sys/types.h> +#include <sys/param.h> +#include <sys/socket.h> diff -Nru ucspi-tcp-0.88/debian/patches/0006-implicit-declarations.patch ucspi-tcp-0.88/debian/patches/0006-implicit-declarations.patch --- ucspi-tcp-0.88/debian/patches/0006-implicit-declarations.patch 1969-12-31 17:00:00.000000000 -0700 +++ ucspi-tcp-0.88/debian/patches/0006-implicit-declarations.patch 2024-04-12 14:33:32.000000000 -0600 @@ -0,0 +1,356 @@ +Description: Add missing includes and prototypes +Author: Zixing Liu <zixing....@canonical.com> +Bug-Debian: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1066629 +Bug-Ubuntu: https://bugs.launchpad.net/ubuntu/+source/ucspi-tcp/+bug/2061188 +Forwarded: no +Last-Update: 2024-04-12 +--- +This patch header follows DEP-3: http://dep.debian.net/deps/dep3/ +Index: ucspi-tcp/dns_random.c +=================================================================== +--- ucspi-tcp.orig/dns_random.c ++++ ucspi-tcp/dns_random.c +@@ -1,3 +1,4 @@ ++#include <unistd.h> + #include "dns.h" + #include "taia.h" + #include "uint32.h" +Index: ucspi-tcp/dns_rcrw.c +=================================================================== +--- ucspi-tcp.orig/dns_rcrw.c ++++ ucspi-tcp/dns_rcrw.c +@@ -1,3 +1,4 @@ ++#include <unistd.h> + #include "taia.h" + #include "env.h" + #include "byte.h" +Index: ucspi-tcp/remoteinfo.c +=================================================================== +--- ucspi-tcp.orig/remoteinfo.c ++++ ucspi-tcp/remoteinfo.c +@@ -1,3 +1,4 @@ ++#include <unistd.h> + #include "fmt.h" + #include "buffer.h" + #include "socket.h" +Index: ucspi-tcp/tcpserver.c +=================================================================== +--- ucspi-tcp.orig/tcpserver.c ++++ ucspi-tcp/tcpserver.c +@@ -1,3 +1,4 @@ ++#include <unistd.h> + #include <sys/types.h> + #include <sys/param.h> + #include <netdb.h> +@@ -63,7 +64,8 @@ static stralloc addresses; + char bspace[16]; + buffer b; + +- ++int socket_ipoptionskill(int s); ++int socket_tcpnodelay(int s); + + /* ---------------------------- child */ + +Index: ucspi-tcp/auto-str.c +=================================================================== +--- ucspi-tcp.orig/auto-str.c ++++ ucspi-tcp/auto-str.c +@@ -1,7 +1,6 @@ + #include "buffer.h" + #include "readwrite.h" + #include "exit.h" +- + char bspace[256]; + buffer b = BUFFER_INIT(write,1,bspace,sizeof bspace); + +Index: ucspi-tcp/chkshsgr.c +=================================================================== +--- ucspi-tcp.orig/chkshsgr.c ++++ ucspi-tcp/chkshsgr.c +@@ -1,3 +1,5 @@ ++#include <unistd.h> ++#include <grp.h> + #include "exit.h" + + main() +Index: ucspi-tcp/dns_transmit.c +=================================================================== +--- ucspi-tcp.orig/dns_transmit.c ++++ ucspi-tcp/dns_transmit.c +@@ -1,8 +1,12 @@ ++#include <sys/types.h> ++#include <sys/socket.h> ++#include <unistd.h> ++#include <stdlib.h> + #include "socket.h" ++#include <errno.h> + #include "alloc.h" + #include "error.h" + #include "byte.h" +-#include "readwrite.h" + #include "uint16.h" + #include "dns.h" + +Index: ucspi-tcp/fd_copy.c +=================================================================== +--- ucspi-tcp.orig/fd_copy.c ++++ ucspi-tcp/fd_copy.c +@@ -1,4 +1,5 @@ + #include <fcntl.h> ++#include <unistd.h> + #include "fd.h" + + int fd_copy(int to,int from) +Index: ucspi-tcp/fd_move.c +=================================================================== +--- ucspi-tcp.orig/fd_move.c ++++ ucspi-tcp/fd_move.c +@@ -1,3 +1,4 @@ ++#include <unistd.h> + #include "fd.h" + + int fd_move(int to,int from) +Index: ucspi-tcp/fixcrio.c +=================================================================== +--- ucspi-tcp.orig/fixcrio.c ++++ ucspi-tcp/fixcrio.c +@@ -1,3 +1,5 @@ ++#include <unistd.h> ++#include "fd.h" + #include "sig.h" + #include "buffer.h" + #include "strerr.h" +Index: ucspi-tcp/hier.c +=================================================================== +--- ucspi-tcp.orig/hier.c ++++ ucspi-tcp/hier.c +@@ -1,5 +1,9 @@ + #include "auto_home.h" + ++void h(char *home, int uid, int gid, int mode); ++void d(char *home, char *subdir, int uid, int gid, int mode); ++void c(char *home, char *subdir, char *file, int uid, int gid, int mode); ++ + void hier() + { + h(auto_home,-1,-1,02755); +Index: ucspi-tcp/install.c +=================================================================== +--- ucspi-tcp.orig/install.c ++++ ucspi-tcp/install.c +@@ -1,3 +1,5 @@ ++#include <sys/stat.h> ++#include <unistd.h> + #include "buffer.h" + #include "strerr.h" + #include "error.h" +Index: ucspi-tcp/instcheck.c +=================================================================== +--- ucspi-tcp.orig/instcheck.c ++++ ucspi-tcp/instcheck.c +@@ -1,5 +1,6 @@ + #include <sys/types.h> + #include <sys/stat.h> ++#include <unistd.h> + #include "strerr.h" + #include "error.h" + #include "readwrite.h" +Index: ucspi-tcp/mconnect-io.c +=================================================================== +--- ucspi-tcp.orig/mconnect-io.c ++++ ucspi-tcp/mconnect-io.c +@@ -1,3 +1,4 @@ ++#include <signal.h> + #include "sig.h" + #include "wait.h" + #include "fork.h" +Index: ucspi-tcp/pathexec_run.c +=================================================================== +--- ucspi-tcp.orig/pathexec_run.c ++++ ucspi-tcp/pathexec_run.c +@@ -1,3 +1,4 @@ ++#include <unistd.h> + #include "error.h" + #include "stralloc.h" + #include "str.h" +Index: ucspi-tcp/prot.c +=================================================================== +--- ucspi-tcp.orig/prot.c ++++ ucspi-tcp/prot.c +@@ -1,3 +1,5 @@ ++#include <unistd.h> ++#include <grp.h> + #include "hasshsgr.h" + #include "prot.h" + +Index: ucspi-tcp/rblsmtpd.c +=================================================================== +--- ucspi-tcp.orig/rblsmtpd.c ++++ ucspi-tcp/rblsmtpd.c +@@ -1,3 +1,4 @@ ++#include <unistd.h> + #include "byte.h" + #include "str.h" + #include "scan.h" +Index: ucspi-tcp/readclose.c +=================================================================== +--- ucspi-tcp.orig/readclose.c ++++ ucspi-tcp/readclose.c +@@ -1,3 +1,4 @@ ++#include <unistd.h> + #include "readwrite.h" + #include "error.h" + #include "readclose.h" +Index: ucspi-tcp/recordio.c +=================================================================== +--- ucspi-tcp.orig/recordio.c ++++ ucspi-tcp/recordio.c +@@ -1,3 +1,5 @@ ++#include <unistd.h> ++#include "fd.h" + #include "sig.h" + #include "buffer.h" + #include "strerr.h" +Index: ucspi-tcp/seek_set.c +=================================================================== +--- ucspi-tcp.orig/seek_set.c ++++ ucspi-tcp/seek_set.c +@@ -1,3 +1,4 @@ ++#include <unistd.h> + #include <sys/types.h> + #include "seek.h" + +Index: ucspi-tcp/sig_pause.c +=================================================================== +--- ucspi-tcp.orig/sig_pause.c ++++ ucspi-tcp/sig_pause.c +@@ -1,3 +1,4 @@ ++#define __USE_XOPEN_EXTENDED 1 + #include <signal.h> + #include "sig.h" + #include "hassgprm.h" +Index: ucspi-tcp/socket_tcp.c +=================================================================== +--- ucspi-tcp.orig/socket_tcp.c ++++ ucspi-tcp/socket_tcp.c +@@ -1,3 +1,4 @@ ++#include <unistd.h> + #include <sys/types.h> + #include <sys/param.h> + #include <sys/socket.h> +Index: ucspi-tcp/socket_udp.c +=================================================================== +--- ucspi-tcp.orig/socket_udp.c ++++ ucspi-tcp/socket_udp.c +@@ -1,3 +1,4 @@ ++#include <unistd.h> + #include <sys/types.h> + #include <sys/param.h> + #include <sys/socket.h> +Index: ucspi-tcp/tcpclient.c +=================================================================== +--- ucspi-tcp.orig/tcpclient.c ++++ ucspi-tcp/tcpclient.c +@@ -1,6 +1,7 @@ + #include <sys/types.h> + #include <sys/param.h> + #include <netdb.h> ++#include <unistd.h> + #include "sig.h" + #include "exit.h" + #include "sgetopt.h" +@@ -24,6 +25,7 @@ + #define FATAL "tcpclient: fatal: " + #define CONNECT "tcpclient: unable to connect to " + ++int socket_tcpnodelay(int s); + void nomem(void) + { + strerr_die2x(111,FATAL,"out of memory"); +Index: ucspi-tcp/tcprules.c +=================================================================== +--- ucspi-tcp.orig/tcprules.c ++++ ucspi-tcp/tcprules.c +@@ -1,3 +1,7 @@ ++#include <stdio.h> ++#include <unistd.h> ++#include "scan.h" ++#include "open.h" + #include "strerr.h" + #include "stralloc.h" + #include "getln.h" +Index: ucspi-tcp/tcprulescheck.c +=================================================================== +--- ucspi-tcp.orig/tcprulescheck.c ++++ ucspi-tcp/tcprulescheck.c +@@ -1,3 +1,5 @@ ++#include <unistd.h> ++#include "open.h" + #include "byte.h" + #include "buffer.h" + #include "strerr.h" +Index: ucspi-tcp/trypoll.c +=================================================================== +--- ucspi-tcp.orig/trypoll.c ++++ ucspi-tcp/trypoll.c +@@ -1,3 +1,4 @@ ++#include <unistd.h> + #include <sys/types.h> + #include <fcntl.h> + #include <poll.h> +Index: ucspi-tcp/tryshsgr.c +=================================================================== +--- ucspi-tcp.orig/tryshsgr.c ++++ ucspi-tcp/tryshsgr.c +@@ -1,3 +1,5 @@ ++#include <unistd.h> ++#include <grp.h> + main() + { + short x[4]; +Index: ucspi-tcp/tryulong32.c +=================================================================== +--- ucspi-tcp.orig/tryulong32.c ++++ ucspi-tcp/tryulong32.c +@@ -1,4 +1,6 @@ +-main() ++#include <unistd.h> ++ ++int main() + { + unsigned long u; + u = 1; +Index: ucspi-tcp/tryulong64.c +=================================================================== +--- ucspi-tcp.orig/tryulong64.c ++++ ucspi-tcp/tryulong64.c +@@ -1,4 +1,5 @@ +-main() ++#include <unistd.h> ++int main() + { + unsigned long u; + u = 1; +Index: ucspi-tcp/tryvfork.c +=================================================================== +--- ucspi-tcp.orig/tryvfork.c ++++ ucspi-tcp/tryvfork.c +@@ -1,3 +1,4 @@ ++#include <unistd.h> + main() + { + vfork(); +Index: ucspi-tcp/readwrite.h +=================================================================== +--- ucspi-tcp.orig/readwrite.h ++++ ucspi-tcp/readwrite.h +@@ -1,7 +1,6 @@ + #ifndef READWRITE_H + #define READWRITE_H + +-extern int read(); +-extern int write(); ++#include <unistd.h> + + #endif diff -Nru ucspi-tcp-0.88/debian/patches/series ucspi-tcp-0.88/debian/patches/series --- ucspi-tcp-0.88/debian/patches/series 2024-02-27 02:57:42.000000000 -0700 +++ ucspi-tcp-0.88/debian/patches/series 2024-04-12 14:20:16.000000000 -0600 @@ -3,3 +3,4 @@ 0003-Makefile-target-choose-do-not-depend-on-conf-home.diff 0004-respect-DESTDIR-variable.patch 0005-build-verbose.patch +0006-implicit-declarations.patch