summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorJens Bache-Wiig <jbache@trolltech.com>2009-05-22 11:52:47 (GMT)
committerJens Bache-Wiig <jbache@trolltech.com>2009-05-22 12:02:20 (GMT)
commitbc498cd027dff6ff16032868c6bb00e634749cd6 (patch)
tree24ea08cddd1e63dc87f4a611c61c9beb75a66271 /src
parentec8c6b9f5a25f9d4c437fbb13f073aeebc09cb3f (diff)
downloadQt-bc498cd027dff6ff16032868c6bb00e634749cd6.zip
Qt-bc498cd027dff6ff16032868c6bb00e634749cd6.tar.gz
Qt-bc498cd027dff6ff16032868c6bb00e634749cd6.tar.bz2
Fix Qt does not compile when glibc < 2.3.2 on linux
Rather than try to resolve functions or impose configure time limitations we simply remove the dependancy entirely and rely on the fallbac for all platforms. Task-number: 250731 Reviewed-by: thiago
Diffstat (limited to 'src')
-rw-r--r--src/gui/styles/gtksymbols.cpp27
1 files changed, 5 insertions, 22 deletions
diff --git a/src/gui/styles/gtksymbols.cpp b/src/gui/styles/gtksymbols.cpp
index 0842ec7..d8a67c2 100644
--- a/src/gui/styles/gtksymbols.cpp
+++ b/src/gui/styles/gtksymbols.cpp
@@ -633,31 +633,14 @@ GtkStyle* QGtk::gtkStyle(const QString &path)
return 0;
}
-#ifdef Q_OS_LINUX
-QT_END_NAMESPACE
-
-int getresuid(uid_t *ruid, uid_t *euid, uid_t *suid);
-int getresgid(gid_t *rgid, gid_t *egid, gid_t *sgid);
-
-QT_BEGIN_NAMESPACE
-#endif
-
void QGtk::initGtkWidgets()
{
// From gtkmain.c
-
- uid_t ruid, rgid, euid, egid, suid, sgid;
-
-#ifdef Q_OS_LINUX
- if (getresuid (&ruid, &euid, &suid) != 0 || getresgid (&rgid, &egid, &sgid) != 0)
-#endif
- {
- suid = ruid = getuid ();
- sgid = rgid = getgid ();
- euid = geteuid ();
- egid = getegid ();
- }
- if (ruid != euid || ruid != suid || rgid != egid || rgid != sgid) {
+ uid_t ruid = getuid ();
+ uid_t rgid = getgid ();
+ uid_t euid = geteuid ();
+ uid_t egid = getegid ();
+ if (ruid != euid || rgid != egid) {
qWarning("\nThis process is currently running setuid or setgid.\nGTK+ does not allow this "
"therefore Qt cannot use the GTK+ integration.\nTry launching your app using \'gksudo\', "
"\'kdesudo\' or a similar tool.\n\n"