strbuf_empty() frees allocated memory and set strbuf to initial state */
| 46 | |
| 47 | /* strbuf_empty() frees allocated memory and set strbuf to initial state */ |
| 48 | void |
| 49 | strbuf_empty(strbuf_t *strbuf) |
| 50 | { |
| 51 | if (strbuf->str != NULL && strbuf->str != strbuf->buf) |
| 52 | free((genericptr_t) strbuf->str); |
| 53 | strbuf_init(strbuf); |
| 54 | } |
| 55 | |
| 56 | /* strbuf_nl_to_crlf() converts all occurrences of \n to \r\n */ |
| 57 | void |
no test coverage detected