Ticket #527 (closed bug: fixed)

Opened 13 years ago

Last modified 13 years ago

SOCK_* definitions vary between target platforms

Reported by: Infinoid Owned by:
Priority: normal Milestone:
Component: none Version:
Severity: medium Keywords:
Cc: Language:
Patch status: applied Platform:

Description

The SOCK_STREAM and SOCK_DGRAM definitions in include/parrot/io.h are correct for linux and win32, but solaris has different values. As a result, the http.pir example tries to create a UDP socket when run on solaris.

These definitions need a lookup table, similar to the one we're using for PF_*.

Attachments

socket6.patch Download (4.6 KB) - added by bacek 13 years ago.
Lookup table for PIO_SOCK
socket7.patch Download (0.8 KB) - added by bacek 13 years ago.
Update examples/io/http.pir to use constants.

Change History

Changed 13 years ago by bacek

Lookup table for PIO_SOCK

Changed 13 years ago by bacek

Update examples/io/http.pir to use constants.

Changed 13 years ago by rg

I can confirm that the patch fixes the stream vs. dgram problem on solaris.

Changed 13 years ago by Infinoid

  • status changed from new to closed
  • resolution set to fixed
  • patch set to applied

Still works for me on linux/amd64 and mingw.

Thanks, applied as r37833. I made some minor whitespace modifications to pass t/codingstd/c_indent.t.

Note: See TracTickets for help on using tickets.