| 1109 | } |
| 1110 | |
| 1111 | int streamcopy(stream *dest, stream *source, int maxlen) |
| 1112 | { |
| 1113 | int got = 0, len; |
| 1114 | uchar copybuf[1024]; |
| 1115 | while(got < maxlen && (len = source->read(copybuf, 1024))) got += dest->write(copybuf, len); |
| 1116 | return got; |
| 1117 | } |
| 1118 | |
| 1119 | #ifndef STANDALONE |
| 1120 | void filerotate(const char *basename, const char *ext, int keepold, const char *oldformat) // rotate old logfiles |
no test coverage detected