diff options
author | Vicent Marti <tanoku@gmail.com> | 2012-08-28 22:19:08 -0700 |
---|---|---|
committer | Vicent Marti <tanoku@gmail.com> | 2012-08-28 23:26:00 -0700 |
commit | 0f4c61754bd123b3bee997b397187c9b813ca3e4 (patch) | |
tree | 4278875a298e527b27a4517f5a054b7e2cf87cee /src/win32/dir.c | |
parent | 6813169ac9fe2558e4503f0149f22c5fad9d61c1 (diff) | |
download | libgit2-utf8-win.tar.gz |
Add bounds checking to UTF-8 conversionutf8-win
Diffstat (limited to 'src/win32/dir.c')
-rw-r--r-- | src/win32/dir.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/win32/dir.c b/src/win32/dir.c index 8b4f8962a..5cb1082bc 100644 --- a/src/win32/dir.c +++ b/src/win32/dir.c @@ -40,7 +40,7 @@ git__DIR *git__opendir(const char *dir) if (!new->dir) goto fail; - git__utf8_to_16(filter_w, filter); + git__utf8_to_16(filter_w, GIT_WIN_PATH, filter); new->h = FindFirstFileW(filter_w, &new->f); if (new->h == INVALID_HANDLE_VALUE) { @@ -116,7 +116,7 @@ void git__rewinddir(git__DIR *d) if (!init_filter(filter, sizeof(filter), d->dir)) return; - git__utf8_to_16(filter_w, filter); + git__utf8_to_16(filter_w, GIT_WIN_PATH, filter); d->h = FindFirstFileW(filter_w, &d->f); if (d->h == INVALID_HANDLE_VALUE) |