From 4b4dbc6d617404ce74a90e9201927686a264b227 Mon Sep 17 00:00:00 2001 From: hauke Date: Wed, 5 Feb 2014 23:10:39 +0000 Subject: [PATCH] xmail: add missing file from r39497. This patch updates xmail to the latest version available, and includes a quick fix for IPv6 support in CtrlClnt (XMail's control client) commandline utility. Signed-off-by: Luis Dallos git-svn-id: svn://svn.openwrt.org/openwrt/packages@39499 3c298f89-4303-0410-b956-a3cf2f4a3e73 --- .../050-ctrlclnt_add_ipv6_support.patch | 56 +++++++++++++++++++ 1 file changed, 56 insertions(+) create mode 100644 mail/xmail/patches/050-ctrlclnt_add_ipv6_support.patch diff --git a/mail/xmail/patches/050-ctrlclnt_add_ipv6_support.patch b/mail/xmail/patches/050-ctrlclnt_add_ipv6_support.patch new file mode 100644 index 000000000..505c0a96b --- /dev/null +++ b/mail/xmail/patches/050-ctrlclnt_add_ipv6_support.patch @@ -0,0 +1,56 @@ +--- a/CTRLClient.cpp ++++ b/CTRLClient.cpp +@@ -53,7 +53,7 @@ struct CClnChannelCfg { + /* Needed by library functions ( START ) */ + bool bServerDebug = false; + int iLogRotateHours = 24; +-int iAddrFamily = AF_INET; ++int iAddrFamily = SYS_INET64; + static char const * const pszCClnErrors[] = { + "Wrong command line usage", + "Either none or both private key and certificate file must be supplied" +@@ -349,7 +349,7 @@ int CClnLogError(int iError) + void CClnShowUsage(char const *pszProgName) + { + fprintf(stderr, +- "use : %s [-snuptfSLcKCXHD] ...\n" ++ "use : %s [-snuptfSLcKCXHD4657] ...\n" + "options :\n" + " -s server = set server address\n" + " -n port = set server port [%d]\n" +@@ -364,7 +364,11 @@ void CClnShowUsage(char const *pszProgNa + " -X filename = set the SSL certificate-list file\n" + " -H dir = set the SSL certificate-store directory\n" + " -c = disable MD5 authentication\n" +- " -D = enable debug\n", ++ " -D = enable debug\n" ++ " -4 = connect only to IPv4 addresses\n" ++ " -6 = connect only to IPv6 addresses\n" ++ " -5 = prefer IPv4 addresses over IPv6 addresses\n" ++ " -7 = prefer IPv6 addresses over IPv4 addresses\n", + pszProgName, STD_CTRL_PORT, STD_CTRL_TIMEOUT); + } + +@@ -467,6 +471,22 @@ int CClnExec(int iArgCount, char *pszArg + bServerDebug = true; + break; + ++ case '4': ++ iAddrFamily = AF_INET; ++ break; ++ ++ case '6': ++ iAddrFamily = AF_INET6; ++ break; ++ ++ case '5': ++ iAddrFamily = SYS_INET46; ++ break; ++ ++ case '7': ++ iAddrFamily = SYS_INET64; ++ break; ++ + default: + return CCLN_ERR_BAD_USAGE; + }