From 5809ae86645be9747e0969854475657ba2a88b7d Mon Sep 17 00:00:00 2001 From: pontscho Date: Wed, 12 Dec 2001 21:47:44 +0000 Subject: [PATCH] gtk suid bug fix(?) git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@3475 b3059339-0415-0410-9bf9-f77b7e298cf2 --- Gui/mplayer/widgets.c | 4 ++++ mplayer.c | 1 + 2 files changed, 5 insertions(+) diff --git a/Gui/mplayer/widgets.c b/Gui/mplayer/widgets.c index 0115a85442..e945761356 100644 --- a/Gui/mplayer/widgets.c +++ b/Gui/mplayer/widgets.c @@ -68,6 +68,10 @@ static void gtkThreadProc( int argc,char * argv[] ) { struct sigaction sa; + #ifdef HAVE_RTC + setuid( getuid() ); // strongly test, please check this. + #endif + gtk_set_locale(); gtk_init( &argc,&argv ); gdk_set_use_xshm( TRUE ); diff --git a/mplayer.c b/mplayer.c index dbca05c518..49af12f9ea 100644 --- a/mplayer.c +++ b/mplayer.c @@ -634,6 +634,7 @@ if(!parse_codec_cfg(get_path("codecs.conf"))){ } else printf("Using Linux's hardware RTC timing (%ldHz)\n", irqp); } + setuid( getuid() ); // strongly test, please check this. if(rtc_fd<0) #endif printf("Using %s timing\n",softsleep?"software":"usleep()");