FreeRADIUS 2 not listening on right port

Phil Mayers p.mayers at imperial.ac.uk
Fri May 16 16:49:16 CEST 2008


Alan DeKok wrote:
> Michael Griego wrote:
>> I did a little looking into this this evening.  This assessment looks to
>> be correct as it looks to be related to compiler optimizations.  With
>> the optimizations disabled in Make.inc, FreeRADIUS will start up on the
>> correct port.  For the fr_socket function, gcc appears to be optimizing
>> the arguments by sending them through the registers instead of the stack
>> frame, but the "port" argument is being clobbered ("optimized out")
>> before the htons(port) call.  Specifically, according to a step-through
>> with GDB, after the first function call in fr_socket (which is to
>> socket()), the port variable is gone ("optimized out").
> 
>   <sigh>  I've started testing the server with other compilers.  GCC is
> getting too ugly for my liking.
> 
>   I'll put a note on the main web page.: DON'T USE -O2 ON FEDORA!

I can confirm this; I've opened a bug in the Fedora bugzilla:

https://bugzilla.redhat.com/show_bug.cgi?id=446864

...with any luck, the toolchain will get fixed - it's clearly not a 
FreeRadius bug, and I wonder what else it's broken...



More information about the Freeradius-Users mailing list