mirror of
https://git.suyu.dev/suyu/breakpad.git
synced 2026-03-08 01:06:27 +00:00
Make my_str_len/my_itos take uintmax_t
R=digit at https://breakpad.appspot.com/452004/ git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@1038 4c0a9323-5329-0410-9bdc-e9ce6186880e
This commit is contained in:
@@ -112,13 +112,13 @@ bool LinuxPtraceDumper::BuildProcPath(char* path, pid_t pid,
|
||||
if (node_len == 0)
|
||||
return false;
|
||||
|
||||
const unsigned pid_len = my_int_len(pid);
|
||||
const unsigned pid_len = my_uint_len(pid);
|
||||
const size_t total_length = 6 + pid_len + 1 + node_len;
|
||||
if (total_length >= NAME_MAX)
|
||||
return false;
|
||||
|
||||
my_memcpy(path, "/proc/", 6);
|
||||
my_itos(path + 6, pid, pid_len);
|
||||
my_uitos(path + 6, pid, pid_len);
|
||||
path[6 + pid_len] = '/';
|
||||
my_memcpy(path + 6 + pid_len + 1, node, node_len);
|
||||
path[total_length] = '\0';
|
||||
|
||||
Reference in New Issue
Block a user