Mercurial > hg > nginx-quic
view src/core/ngx_string.c @ 27:a8d5abe713e6
nginx-0.0.1-2002-12-15-20:10:12 import
author | Igor Sysoev <igor@sysoev.ru> |
---|---|
date | Sun, 15 Dec 2002 17:10:12 +0000 |
parents | 4eff17414a43 |
children | e43f406e4525 |
line wrap: on
line source
#include <ngx_config.h> #include <ngx_string.h> char *ngx_cpystrn(char *dst, char *src, size_t n) { if (n == 0) return dst; for (/* void */; --n; dst++, src++) { *dst = *src; if (*dst == '\0') return dst; } *dst = '\0'; return dst; }