git/list[1] front-page[2] threads[3] people[4] search[5] about
 

[PATCH] tmp-objdir: mark some file local symbols static

From
Ramsay Jones <ramsay@ramsayjones.plus.com>
Date
Oct 1, 2016, 23:07 UTC
Message-ID
<f5560f8b-75be-faa0-ce1c-5e2716ee82a5@ramsayjones.plus.com>
Signed-off-by: Ramsay Jones <ramsay@ramsayjones.plus.com>
---
Hi Jeff,

If you need to re-roll your 'jk/quarantine-received-objects' branch, could you please squash this into the relevant patches.

[I also note that tmp_objdir_destroy(), declared to be part of the public interface, is not currently called from outside tmp_objdir.c. Despite being unlikely, it is at least plausible that this function may be useful in future. ;-) ]

Thanks!

ATB, Ramsay Jones

 builtin/receive-pack.c | 2 +-
 tmp-objdir.c           | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/builtin/receive-pack.c b/builtin/receive-pack.c
index 25afa3f..4194088 100644
--- a/builtin/receive-pack.c
+++ b/builtin/receive-pack.c
@@ -87,7 +87,7 @@ static enum {
 } use_keepalive;
 static int keepalive_in_sec = 5;
 
-struct tmp_objdir *tmp_objdir;
+static struct tmp_objdir *tmp_objdir;
 
 static enum deny_action parse_deny_action(const char *var, const char *value)
 {
diff --git a/tmp-objdir.c b/tmp-objdir.c
index 2181a42..3a58404 100644
--- a/tmp-objdir.c
+++ b/tmp-objdir.c
@@ -17,7 +17,7 @@ struct tmp_objdir {
  * more than one, and we can expand later if so.  You can have many such
  * tmp_objdirs simultaneously in many processes, of course.
  */
-struct tmp_objdir *the_tmp_objdir;
+static struct tmp_objdir *the_tmp_objdir;
 
 static void tmp_objdir_free(struct tmp_objdir *t)
 {
-- 
2.10.0
Next: Jeff King
Message 1 of 2 in “tmp-objdir: mark some file local symbols static”
  1. tmp-objdir: mark some file local symbols staticRamsay Jones, Oct 1, 2016
  2. Jeff KingOct 2, 2016

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.