int/u_int Data Types Used

Frank-M Mohr frank-m.mohr at db.com
Wed Aug 15 06:35:39 EST 2001



I was looking after some compiler warnings in openssh-2.9p2, same with yesterday's snap
(about 15 Warnings, some for void*/function ptr warnings)
IBM's compiler gives warnings, gcc on Linux doesn't complain about them.

Example:
"authfd.c", line 414.49: 1506-280 (W) Function argument assignment between types "unsigned int*" and "int*" is not allowed.

I found a few things:

- pointers to signed/unsigned ints are used for buffer/packet length parameters
  -> should I try to fix these warnings / maximum buffer size is defined as 256k so there should be no problem to use a typecast

- in configure the size of int is checked, but 2 byte int's (Ansi C minimum) would cause an overflow for buffer sizes of 256k
  -> shouldn't configure stop there? (btw are 16bit ints still used on any unix systems? minix or embeded systems might do so)


frank



--

Diese E-Mail enthält vertrauliche und/oder rechtlich geschützte Informationen. Wenn Sie nicht der richtige Adressat sind oder diese E-Mail irrtümlich erhalten haben, informieren Sie bitte sofort den Absender und vernichten Sie diese Mail. Das unerlaubte Kopieren sowie die unbefugte Weitergabe dieser Mail ist nicht gestattet.

This e-mail may contain confidential and/or privileged information. If you are not the intended recipient (or have received this e-mail in error) please notify the sender immediately and destroy this e-mail. Any unauthorized copying, disclosure or distribution of the material in this e-mail is strictly forbidden.





More information about the openssh-unix-dev mailing list