glibc, egcs, czy co?

Ziemek Borowski ziembor w FAQ-bot.ZiemBor.Waw.PL
Śro, 3 Lut 1999, 13:02:37 CET


[wtorek, 02 luty 1999], Marek Obuchowicz napisał(a):

> > To raczej kwestia security. Ale niech sie ktos obeznany w C wypowie na ten
> > temat ...
> dlaczego we wszystkich programach nalezy zrezygnowac z strcpy()?
> Ze wzgledow bezpieczenstwa? dobry powod ale nie kazdy strcpy jest
> krytyczne!
glibc 2.1 FAQ: 
{UD} Another problem in this area is that gcc still has problems on machines
with very few registers (e.g., ix86).  The inline assembler code can require
almost all the registers and the register allocator cannot always handle
this situation.

One can disable the string optimizations selectively.  Instead of writing

        cp = strcpy (foo, "lkj");

one can write

        cp = (strcpy) (foo, "lkj");

This disables the optimization for that specific call.




Więcej informacji o liście dyskusyjnej pld-devel-pl