Please do not reply directly to this email. All additional comments should be made in the comments box of this bug report. https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=207838 Summary: Perl getsockopt() on SCTP sockets doesn't work Product: Fedora Core Version: fc5 Platform: x86_64 OS/Version: Linux Status: NEW Severity: normal Priority: normal Component: perl AssignedTo: rnorwood@xxxxxxxxxx ReportedBy: pablo_p@xxxxx QAContact: dkl@xxxxxxxxxx CC: fedora-perl-devel-list@xxxxxxxxxx Description of problem: Perl getsockopt() on SCTP socket does not work. Following perl code: ------------------------------------------ use strict; use IO::Socket; ## create sctp socket my $sock = new IO::Socket::INET( Proto => 132, Type => SOCK_STREAM ) or die "Cannot create sctp socket"; ## read rto data my $i = getsockopt($sock, 132, 1); #print rto data print join("\n", unpack("I i*", $i)); ------------------------------------------ Works on Solaris10, but not on (my) Linux. I checked C getsockopt, and code like this: ret = getsockopt(sock , SOL_SCTP, SCTP_RTOINFO, &sctp_info, &len); works OK only if len is initially set to sizeof(struct sctp_rtoinfo), which is not what manual says: ------------------------------------------- > man getsockopt ... The parameters optval and optlen are used to access option values for setsockopt(). For getsockopt() they identify a buffer in which the value for the requested option(s) are to be returned. For getsock- opt(), optlen is a value-result parameter, initially containing the size of the buffer pointed to by optval, and modified on return to indicate the actual size of the value returned. If no option value is to be supplied or returned, optval may be NULL. ... ------------------------------------------- Above applies to all SCTP structures available via get/setsockopt. Version-Release number of selected component (if applicable): perl-5.8.8-5 glibc-2.4-11 kernel-2.6.17-1.2187_FC5 How reproducible: every time Steps to Reproduce: 1. run perl code from description 2. nothing is displayed Actual results: nothing is displayed Expected results: sctp socket rto into (4 parameters) Additional info: SELinux is disabled. -- Configure bugmail: https://bugzilla.redhat.com/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug, or are watching someone who is.