win: remove duplicated code when processing fsevents

PR-URL: https://github.com/libuv/libuv/pull/756
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
This commit is contained in:
Saúl Ibarra Corretgé 2016-03-08 09:32:39 +01:00
parent 365bdec434
commit 86051a49d8

View File

@ -437,17 +437,7 @@ void uv_process_fs_event_req(uv_loop_t* loop, uv_req_t* req,
long_filenamew = NULL; long_filenamew = NULL;
} }
} }
/*
* We could not resolve the long form explicitly.
* We therefore use the name given by ReadDirectoryChangesW.
* This may be the long form or the 8.3 short name in some cases.
*/
if (!long_filenamew) {
filenamew = file_info->FileName;
sizew = file_info->FileNameLength / sizeof(WCHAR);
} }
} else {
/* /*
* Removed or renamed events cannot be resolved to the long form. * Removed or renamed events cannot be resolved to the long form.
* We therefore use the name given by ReadDirectoryChangesW. * We therefore use the name given by ReadDirectoryChangesW.
@ -457,7 +447,6 @@ void uv_process_fs_event_req(uv_loop_t* loop, uv_req_t* req,
filenamew = file_info->FileName; filenamew = file_info->FileName;
sizew = file_info->FileNameLength / sizeof(WCHAR); sizew = file_info->FileNameLength / sizeof(WCHAR);
} }
}
} else { } else {
/* We already have the long name of the file, so just use it. */ /* We already have the long name of the file, so just use it. */
filenamew = handle->filew; filenamew = handle->filew;