Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl-Sensitive Sunglasses

Re: How is perl able to handle the null byte?

by Moron (Curate)
on Jun 16, 2006 at 09:26 UTC ( #555722=note: print w/ replies, xml ) Need Help??

in reply to How is perl able to handle the null byte?

C does not treat the null byte as the end of a string unless it is told to do so by the variable length string datatype - an array of char is not zero terminated and a pointer to char has no termination at all. In C you can even assign a pointer to char to the address of the first character of your variable length string in order to betray it by walking ad libitum off the end until the operating system detects an access violation - its why strong typing isn't as safe as its cracked out to be.


Free your mind

Comment on Re: How is perl able to handle the null byte?

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://555722]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others browsing the Monastery: (5)
As of 2015-11-26 23:40 GMT
Find Nodes?
    Voting Booth?

    What would be the most significant thing to happen if a rope (or wire) tied the Earth and the Moon together?

    Results (710 votes), past polls