{"thread":{"id":"37076","subject":"[PATCH] path: for clarity, rename get_pathname to get_path_buffer","startedAt":"2014-07-08T12:35:13Z","lastAt":"2014-07-08T13:15:41Z","messageCount":2,"participants":["Michal Nazarewicz"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"245525","messageId":"xa1ta98k58qm.fsf@mina86.com","threadId":"37076","inReplyTo":null,"subject":"[PATCH] path: for clarity, rename get_pathname to get_path_buffer","fromName":"Michal Nazarewicz","fromEmail":"mina86@mina86.com","sentAt":"2014-07-08T12:35:13Z","receivedAt":"2014-07-08T12:35:13Z","isPatch":true,"sender":{"key":"mina86@mina86.com","avatar":"https://avatars.githubusercontent.com/u/32383?v=4"},"body":"The get_pathname function does not really return path name but rather\na buffer to store pathname in.  As such, current name is a bit\nconfusing.  Change the name as to make it clearer what the function is\ndoing.\n\nSigned-off-by: Michal Nazarewicz <mina86@mina86.com>\n---\n path.c | 8 ++++----\n 1 file changed, 4 insertions(+), 4 deletions(-)\n\ndiff --git a/path.c b/path.c\nindex bc804a3..70e2f85 100644\n--- a/path.c\n+++ b/path.c\n@@ -16,7 +16,7 @@ static int get_st_mode_bits(const char *path, int *mode)\n \n static char bad_path[] = \"/bad-path/\";\n \n-static char *get_pathname(void)\n+static char *get_path_buffer(void)\n {\n \tstatic char pathname_array[4][PATH_MAX];\n \tstatic int index;\n@@ -108,7 +108,7 @@ char *mkpath(const char *fmt, ...)\n {\n \tva_list args;\n \tunsigned len;\n-\tchar *pathname = get_pathname();\n+\tchar *pathname = get_path_buffer();\n \n \tva_start(args, fmt);\n \tlen = vsnprintf(pathname, PATH_MAX, fmt, args);\n@@ -120,7 +120,7 @@ char *mkpath(const char *fmt, ...)\n \n char *git_path(const char *fmt, ...)\n {\n-\tchar *pathname = get_pathname();\n+\tchar *pathname = get_path_buffer();\n \tva_list args;\n \tchar *ret;\n \n@@ -158,7 +158,7 @@ void home_config_paths(char **global, char **xdg, char *file)\n \n char *git_path_submodule(const char *path, const char *fmt, ...)\n {\n-\tchar *pathname = get_pathname();\n+\tchar *pathname = get_path_buffer();\n \tstruct strbuf buf = STRBUF_INIT;\n \tconst char *git_dir;\n \tva_list args;\n-- \n2.0.0.526.g5318336\n"},{"id":"245527","messageId":"xa1t4mys56v6.fsf@mina86.com","threadId":"37076","inReplyTo":"xa1ta98k58qm.fsf@mina86.com","subject":"[PATCH] path: for clarity, rename get_pathname to get_path_buffer","fromName":"Michal Nazarewicz","fromEmail":"mina86@mina86.com","sentAt":"2014-07-08T13:15:41Z","receivedAt":"2014-07-08T13:15:41Z","isPatch":true,"sender":{"key":"mina86@mina86.com","avatar":"https://avatars.githubusercontent.com/u/32383?v=4"},"body":"The get_pathname function does not really return path name but rather\na buffer to store pathname in.  As such, current name is a bit\nconfusing.  Change the name as to make it clearer what the function is\ndoing.\n\nSigned-off-by: Michal Nazarewicz <mina86@mina86.com>\n---\n path.c | 8 ++++----\n 1 file changed, 4 insertions(+), 4 deletions(-)\n\n This time sent with Junio's correct address.\n\ndiff --git a/path.c b/path.c\nindex bc804a3..70e2f85 100644\n--- a/path.c\n+++ b/path.c\n@@ -16,7 +16,7 @@ static int get_st_mode_bits(const char *path, int *mode)\n \n static char bad_path[] = \"/bad-path/\";\n \n-static char *get_pathname(void)\n+static char *get_path_buffer(void)\n {\n \tstatic char pathname_array[4][PATH_MAX];\n \tstatic int index;\n@@ -108,7 +108,7 @@ char *mkpath(const char *fmt, ...)\n {\n \tva_list args;\n \tunsigned len;\n-\tchar *pathname = get_pathname();\n+\tchar *pathname = get_path_buffer();\n \n \tva_start(args, fmt);\n \tlen = vsnprintf(pathname, PATH_MAX, fmt, args);\n@@ -120,7 +120,7 @@ char *mkpath(const char *fmt, ...)\n \n char *git_path(const char *fmt, ...)\n {\n-\tchar *pathname = get_pathname();\n+\tchar *pathname = get_path_buffer();\n \tva_list args;\n \tchar *ret;\n \n@@ -158,7 +158,7 @@ void home_config_paths(char **global, char **xdg, char *file)\n \n char *git_path_submodule(const char *path, const char *fmt, ...)\n {\n-\tchar *pathname = get_pathname();\n+\tchar *pathname = get_path_buffer();\n \tstruct strbuf buf = STRBUF_INIT;\n \tconst char *git_dir;\n \tva_list args;\n-- \n2.0.0.526.g5318336\n"}]}