- sync signal race fix

- disable IDN support by default

From: KDE CVS
This commit is contained in:
brad 2005-02-27 07:25:50 +00:00
parent c5d2bde511
commit 1ec98e242a
3 changed files with 73 additions and 31 deletions

View File

@ -1,10 +1,10 @@
# $OpenBSD: Makefile,v 1.47 2005/02/14 14:10:30 espie Exp $
# $OpenBSD: Makefile,v 1.48 2005/02/27 07:25:50 brad Exp $
COMMENT= "K Desktop Environment, libraries"
CATEGORIES= x11 x11/kde
VERSION= 3.3.2
DISTNAME= kdelibs-${VERSION}
PKGNAME= ${DISTNAME}p3
PKGNAME= ${DISTNAME}p4
MODKDE_VERSION?= 3.3.0
FLAVORS=debug

View File

@ -1,18 +1,27 @@
$OpenBSD: patch-kdecore_kprocctrl_cpp,v 1.1 2005/01/28 09:40:30 espie Exp $
--- kdecore/kprocctrl.cpp.orig Fri Jan 28 02:37:56 2005
+++ kdecore/kprocctrl.cpp Fri Jan 28 02:39:25 2005
@@ -39,7 +39,10 @@ int KProcessController::refCount;
$OpenBSD: patch-kdecore_kprocctrl_cpp,v 1.2 2005/02/27 07:25:51 brad Exp $
--- kdecore/kprocctrl.cpp.orig Sun Nov 30 04:46:44 2003
+++ kdecore/kprocctrl.cpp Sun Feb 27 02:13:52 2005
@@ -38,8 +38,10 @@ int KProcessController::refCount;
void KProcessController::ref()
{
if( !refCount )
+ {
- if( !refCount )
+ if( !refCount ) {
theKProcessController = new KProcessController;
+ setupHandlers();
+ }
refCount++;
}
@@ -71,7 +74,6 @@ KProcessController::KProcessController()
@@ -47,6 +49,7 @@ void KProcessController::deref()
{
refCount--;
if( !refCount ) {
+ resetHandlers();
delete theKProcessController;
theKProcessController = 0;
}
@@ -71,13 +74,10 @@ KProcessController::KProcessController()
QObject::connect( notifier, SIGNAL(activated(int)),
SLOT(slotDoHousekeeping()));
@ -20,3 +29,9 @@ $OpenBSD: patch-kdecore_kprocctrl_cpp,v 1.1 2005/01/28 09:40:30 espie Exp $
}
KProcessController::~KProcessController()
{
- resetHandlers();
-
delete notifier;
close( fd[0] );

View File

@ -1,7 +1,15 @@
$OpenBSD: patch-kdecore_network_kresolver_cpp,v 1.3 2004/12/12 11:33:24 espie Exp $
--- kdecore/network/kresolver.cpp.orig Sun Nov 28 18:30:44 2004
+++ kdecore/network/kresolver.cpp Mon Dec 6 11:59:15 2004
@@ -58,6 +58,10 @@
$OpenBSD: patch-kdecore_network_kresolver_cpp,v 1.4 2005/02/27 07:25:51 brad Exp $
--- kdecore/network/kresolver.cpp.orig Sun Nov 28 12:30:44 2004
+++ kdecore/network/kresolver.cpp Sun Feb 27 02:18:36 2005
@@ -32,6 +32,7 @@
#include <time.h>
#include <arpa/inet.h>
#include <netinet/in.h>
+#include <stdlib.h>
// Qt includes
#include <qapplication.h>
@@ -58,6 +59,10 @@
#include "kresolver_p.h"
#include "ksocketaddress.h"
@ -12,7 +20,7 @@ $OpenBSD: patch-kdecore_network_kresolver_cpp,v 1.3 2004/12/12 11:33:24 espie Ex
using namespace KNetwork;
using namespace KNetwork::Internal;
@@ -622,17 +626,28 @@ QStrList KResolver::protocolName(int pro
@@ -622,17 +627,28 @@ QStrList KResolver::protocolName(int pro
pe = getprotobynumber(protonum);
#else
@ -44,7 +52,7 @@ $OpenBSD: patch-kdecore_network_kresolver_cpp,v 1.3 2004/12/12 11:33:24 espie Ex
{
buflen += 1024;
delete [] buf;
@@ -641,6 +656,7 @@ QStrList KResolver::protocolName(int pro
@@ -641,6 +657,7 @@ QStrList KResolver::protocolName(int pro
break;
}
while (pe == 0L);
@ -52,7 +60,7 @@ $OpenBSD: patch-kdecore_network_kresolver_cpp,v 1.3 2004/12/12 11:33:24 espie Ex
#endif
// Do common processing
@@ -653,7 +669,9 @@ QStrList KResolver::protocolName(int pro
@@ -653,7 +670,9 @@ QStrList KResolver::protocolName(int pro
}
#ifdef HAVE_GETPROTOBYNAME_R
@ -62,7 +70,7 @@ $OpenBSD: patch-kdecore_network_kresolver_cpp,v 1.3 2004/12/12 11:33:24 espie Ex
#endif
return lst;
@@ -668,17 +686,27 @@ QStrList KResolver::protocolName(const c
@@ -668,17 +687,27 @@ QStrList KResolver::protocolName(const c
pe = getprotobyname(protoname);
#else
@ -93,7 +101,7 @@ $OpenBSD: patch-kdecore_network_kresolver_cpp,v 1.3 2004/12/12 11:33:24 espie Ex
{
buflen += 1024;
delete [] buf;
@@ -687,6 +715,7 @@ QStrList KResolver::protocolName(const c
@@ -687,6 +716,7 @@ QStrList KResolver::protocolName(const c
break;
}
while (pe == 0L);
@ -101,7 +109,7 @@ $OpenBSD: patch-kdecore_network_kresolver_cpp,v 1.3 2004/12/12 11:33:24 espie Ex
#endif
// Do common processing
@@ -699,7 +728,9 @@ QStrList KResolver::protocolName(const c
@@ -699,7 +729,9 @@ QStrList KResolver::protocolName(const c
}
#ifdef HAVE_GETPROTOBYNAME_R
@ -111,7 +119,7 @@ $OpenBSD: patch-kdecore_network_kresolver_cpp,v 1.3 2004/12/12 11:33:24 espie Ex
#endif
return lst;
@@ -714,17 +745,28 @@ int KResolver::protocolNumber(const char
@@ -714,17 +746,28 @@ int KResolver::protocolNumber(const char
pe = getprotobyname(protoname);
#else
@ -143,7 +151,7 @@ $OpenBSD: patch-kdecore_network_kresolver_cpp,v 1.3 2004/12/12 11:33:24 espie Ex
{
buflen += 1024;
delete [] buf;
@@ -733,6 +775,7 @@ int KResolver::protocolNumber(const char
@@ -733,6 +776,7 @@ int KResolver::protocolNumber(const char
break;
}
while (pe == 0L);
@ -151,7 +159,7 @@ $OpenBSD: patch-kdecore_network_kresolver_cpp,v 1.3 2004/12/12 11:33:24 espie Ex
#endif
// Do common processing
@@ -741,7 +784,9 @@ int KResolver::protocolNumber(const char
@@ -741,7 +785,9 @@ int KResolver::protocolNumber(const char
protonum = pe->p_proto;
#ifdef HAVE_GETPROTOBYNAME_R
@ -161,7 +169,7 @@ $OpenBSD: patch-kdecore_network_kresolver_cpp,v 1.3 2004/12/12 11:33:24 espie Ex
#endif
return protonum;
@@ -756,17 +801,27 @@ int KResolver::servicePort(const char *s
@@ -756,17 +802,27 @@ int KResolver::servicePort(const char *s
se = getservbyname(servname, protoname);
#else
@ -192,7 +200,7 @@ $OpenBSD: patch-kdecore_network_kresolver_cpp,v 1.3 2004/12/12 11:33:24 espie Ex
{
buflen += 1024;
delete [] buf;
@@ -775,6 +830,7 @@ int KResolver::servicePort(const char *s
@@ -775,6 +831,7 @@ int KResolver::servicePort(const char *s
break;
}
while (se == 0L);
@ -200,7 +208,7 @@ $OpenBSD: patch-kdecore_network_kresolver_cpp,v 1.3 2004/12/12 11:33:24 espie Ex
#endif
// Do common processing
@@ -783,7 +839,9 @@ int KResolver::servicePort(const char *s
@@ -783,7 +840,9 @@ int KResolver::servicePort(const char *s
servport = ntohs(se->s_port);
#ifdef HAVE_GETSERVBYNAME_R
@ -210,7 +218,7 @@ $OpenBSD: patch-kdecore_network_kresolver_cpp,v 1.3 2004/12/12 11:33:24 espie Ex
#endif
return servport;
@@ -798,17 +856,27 @@ QStrList KResolver::serviceName(const ch
@@ -798,17 +857,27 @@ QStrList KResolver::serviceName(const ch
se = getservbyname(servname, protoname);
#else
@ -241,7 +249,7 @@ $OpenBSD: patch-kdecore_network_kresolver_cpp,v 1.3 2004/12/12 11:33:24 espie Ex
{
buflen += 1024;
delete [] buf;
@@ -817,6 +885,7 @@ QStrList KResolver::serviceName(const ch
@@ -817,6 +886,7 @@ QStrList KResolver::serviceName(const ch
break;
}
while (se == 0L);
@ -249,7 +257,7 @@ $OpenBSD: patch-kdecore_network_kresolver_cpp,v 1.3 2004/12/12 11:33:24 espie Ex
#endif
// Do common processing
@@ -829,7 +898,9 @@ QStrList KResolver::serviceName(const ch
@@ -829,7 +899,9 @@ QStrList KResolver::serviceName(const ch
}
#ifdef HAVE_GETSERVBYNAME_R
@ -259,7 +267,7 @@ $OpenBSD: patch-kdecore_network_kresolver_cpp,v 1.3 2004/12/12 11:33:24 espie Ex
#endif
return lst;
@@ -844,17 +915,27 @@ QStrList KResolver::serviceName(int port
@@ -844,17 +916,27 @@ QStrList KResolver::serviceName(int port
se = getservbyport(port, protoname);
#else
@ -290,7 +298,7 @@ $OpenBSD: patch-kdecore_network_kresolver_cpp,v 1.3 2004/12/12 11:33:24 espie Ex
{
buflen += 1024;
delete [] buf;
@@ -863,6 +944,7 @@ QStrList KResolver::serviceName(int port
@@ -863,6 +945,7 @@ QStrList KResolver::serviceName(int port
break;
}
while (se == 0L);
@ -298,7 +306,7 @@ $OpenBSD: patch-kdecore_network_kresolver_cpp,v 1.3 2004/12/12 11:33:24 espie Ex
#endif
// Do common processing
@@ -875,7 +957,9 @@ QStrList KResolver::serviceName(int port
@@ -875,7 +958,9 @@ QStrList KResolver::serviceName(int port
}
#ifdef HAVE_GETSERVBYNAME_R
@ -308,3 +316,22 @@ $OpenBSD: patch-kdecore_network_kresolver_cpp,v 1.3 2004/12/12 11:33:24 espie Ex
#endif
return lst;
@@ -889,6 +974,9 @@ static QString ToUnicode(const QString&
// implement the ToAscii function, as described by IDN documents
QCString KResolver::domainToAscii(const QString& unicodeDomain)
{
+ if (getenv("KDE_USE_IDN") == 0L)
+ return unicodeDomain.latin1();
+
QCString retval;
// RFC 3490, section 4 describes the operation:
// 1) this is a query, so don't allow unassigned
@@ -928,6 +1016,8 @@ QString KResolver::domainToUnicode(const
{
if (asciiDomain.isEmpty())
return asciiDomain;
+ if (getenv("KDE_USE_IDN") == 0L)
+ return asciiDomain;;
QString retval;