Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW

Re: RawIP compile problems

by tachyon (Chancellor)
on Dec 31, 2004 at 06:49 UTC ( #418480=note: print w/replies, xml ) Need Help??

in reply to RawIP compile problems

It works for me on linux but I think your compiler may be choking on an extended line in RawIP.xs:

sv_catpvn(ip_opts,SvPV(*av_fetch(opts,i+2,0),l), SvCUR(*av_fetch(opts,i+2,0))); break; default: } /* reported error line 444 */ sv_catpvn(ip_opts,SvPV(*av_fetch(opts,i+2,0),l), SvCUR(*av_fetch(opts,i+2,0))); break; default: } /* reported error line 543 */

Basically the code before the first two errors (which will be fatal unlike the warnings) is just a loop with a switch statement in it. I have a feeling that your compiler does not like the sv_catpvn(...) being on two lines without a \ line continuation. Try changing it to:

sv_catpvn(ip_opts,SvPV(*av_fetch(opts,i+2,0),l),SvCUR(*av_fetch(opts,i ++2,0))); # or sv_catpvn(ip_opts,SvPV(*av_fetch(opts,i+2,0),l), \ SvCUR(*av_fetch(opts,i+2,0)));



Replies are listed 'Best First'.
Re^2: RawIP compile problems
by Anonymous Monk on Dec 31, 2004 at 11:45 UTC
    I have the feeling the compiler doesn't like the default:, with nothing following it. The compiler choking over a newline seems too far fetched - nor does the error message suggest anything like that. On the other hand, error: label at end of compound statement strongly suggests the problem lies with a label at the end of a compound statement. Like default:.

    I'd try default: ;, or default: break;, or if that doesn't work, removing the default lines.

      I had the same problem. '%s/default:/default: ;/g' in vi fixed it. Thanks!

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://418480]
[Corion]: Oh. I've run out of prewritten articles. I need to release some more modules and write some more articles then ;)
choroba still has one more.

How do I use this? | Other CB clients
Other Users?
Others scrutinizing the Monastery: (5)
As of 2017-04-24 08:49 GMT
Find Nodes?
    Voting Booth?
    I'm a fool:

    Results (437 votes). Check out past polls.