in reply to Re^4: String manipulation
in thread String manipulation

To be clear: moritz was talking about "removing all initial non-whitespace characters", and saying that it would be "not so safe" to do that -- and he would be right, in the sense that sometimes, initial non-whitespace characters might not be garbage, and it would be bad to remove them.

GrandFather has proposed a different approach: just remove null bytes. There is nothing "unsafe" about this -- null bytes carry no relevant information, and they just get in the way. Deleting null bytes from your strings is a Good Thing.