Beefy Boxes and Bandwidth Generously Provided by pair Networks
Keep It Simple, Stupid
 
PerlMonks  

Re: search and replace (in-place) strings in binary

by ikegami (Pope)
on Jul 16, 2020 at 16:46 UTC ( #11119414=note: print w/replies, xml ) Need Help??


in reply to search and replace (in-place) strings in binary

That technically doesn't open the file in binary mode, but there's no difference between text mode and binary mode (by default) in Linux.

But you are reading the file a line at a time. What's a line in a binary file? That makes no sense. Perhaps you should make it so the entire file is one line by using -0777. (That's a zero.)

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others contemplating the Monastery: (4)
As of 2021-02-27 21:32 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?