[vlc-devel] svn commit r9037 seems to have broken MacOS X build

Joe Chan firstian at rcn.com
Sun Oct 24 21:19:19 CEST 2004


After updating, I got the error:

src/misc/threads.c: In function `__vlc_thread_create':
src/misc/threads.c:590: error: parse error before "else"
src/misc/threads.c:593: warning: no return statement in function 
returning non-void

Looking at the code:

#ifndef SYS_DARWIN
     if ( config_GetInt( p_this, "rt-priority" ) )
#endif
     {
         int i_error, i_policy;
         struct sched_param param;

         memset( &param, 0, sizeof(struct sched_param) );
         i_priority += config_GetInt( p_this, "rt-offset" );
         if ( i_priority <= 0 )
         {
             param.sched_priority = (-1) * i_priority;
             i_policy = SCHED_OTHER;
         }
         else
         {
             param.sched_priority = i_priority;
             i_policy = SCHED_RR;
         }
         if ( (i_error = pthread_setschedparam( p_this->thread_id,
                                                i_policy, &param )) )
         {
             msg_Warn( p_this, "couldn't set thread priority (%s:%d): 
%s",
                       psz_file, i_line, strerror(i_error) );
             i_priority = 0;
         }
     }
     else
     {
         i_priority = 0;
     }

Looks like the #endif should be moved to just after else? The thing for 
__vlc_thread_set_priority().

--
Joe Chan
Sun Microsystems, Inc.
Burlington, MA
Tel: (781) 442-0809

-- 
This is the vlc-devel mailing-list, see http://www.videolan.org/vlc/
To unsubscribe, please read http://developers.videolan.org/lists.html



More information about the vlc-devel mailing list