include: avoid using C++ 'template' reserved word

Closes #1394
This commit is contained in:
Iñaki Baz Castillo 2014-08-06 11:47:08 +02:00
parent c7e4b31444
commit a1ff22cb7e
3 changed files with 5 additions and 5 deletions

View File

@ -1892,7 +1892,7 @@ UV_EXTERN int uv_fs_write(uv_loop_t* loop, uv_fs_t* req, uv_file file,
UV_EXTERN int uv_fs_mkdir(uv_loop_t* loop, uv_fs_t* req, const char* path,
int mode, uv_fs_cb cb);
UV_EXTERN int uv_fs_mkdtemp(uv_loop_t* loop, uv_fs_t* req, const char* template,
UV_EXTERN int uv_fs_mkdtemp(uv_loop_t* loop, uv_fs_t* req, const char* tpl,
uv_fs_cb cb);
UV_EXTERN int uv_fs_rmdir(uv_loop_t* loop, uv_fs_t* req, const char* path,

View File

@ -1009,10 +1009,10 @@ int uv_fs_mkdir(uv_loop_t* loop,
int uv_fs_mkdtemp(uv_loop_t* loop,
uv_fs_t* req,
const char* template,
const char* tpl,
uv_fs_cb cb) {
INIT(MKDTEMP);
req->path = strdup(template);
req->path = strdup(tpl);
if (req->path == NULL)
return -ENOMEM;
POST;

View File

@ -1797,13 +1797,13 @@ int uv_fs_mkdir(uv_loop_t* loop, uv_fs_t* req, const char* path, int mode,
}
int uv_fs_mkdtemp(uv_loop_t* loop, uv_fs_t* req, const char* template,
int uv_fs_mkdtemp(uv_loop_t* loop, uv_fs_t* req, const char* tpl,
uv_fs_cb cb) {
int err;
uv_fs_req_init(loop, req, UV_FS_MKDTEMP, cb);
err = fs__capture_path(loop, req, template, NULL, TRUE);
err = fs__capture_path(loop, req, tpl, NULL, TRUE);
if (err)
return uv_translate_sys_error(err);