Closed miopa closed 4 years ago
Is updating the message
string in place a better way?
Is updating the message string in place a better way?
Neither better nor worse. It might provide better cpu cache locality? But that's a really totally irrelevant optimization here.
Using what already exists is what matters here :)
AMI is a telnet based protocol
Oh, and don't call it telnet-based. It's a text-based protocol. The fact that some people use the telnet(1) application when they want netcat(1) creates this confusion. Don't spread it.
Also, please squash your commits to a single one and update the commit msg.
I'll send a new PR if code is good, that seems easier right now
astman_send_error (
<- one space too many.
Other than that, LGTM!
AMI is a telnet based protocol in which literal newline can't be passed. One possible solution is encoding the newline with '\n' or '\r' sequence in the SMS text