mirror of
https://git.proxmox.com/git/libgit2
synced 2025-06-21 15:07:23 +00:00
cl_git_path_url: assert sane static buffer size
This commit is contained in:
parent
4cc355c97b
commit
8452fecc8f
@ -299,6 +299,8 @@ const char* cl_git_path_url(const char *path)
|
|||||||
in_buf++;
|
in_buf++;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
cl_assert(url_buf.size < 4096);
|
||||||
|
|
||||||
strncpy(url, git_buf_cstr(&url_buf), 4096);
|
strncpy(url, git_buf_cstr(&url_buf), 4096);
|
||||||
git_buf_free(&url_buf);
|
git_buf_free(&url_buf);
|
||||||
git_buf_free(&path_buf);
|
git_buf_free(&path_buf);
|
||||||
|
Loading…
Reference in New Issue
Block a user