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

[patch-git] Fix warning in convert-cache

From
tony.luck@intel.com <tony.luck@intel.com>
Date
May 2, 2005, 17:57 UTC
Message-ID
<200505021757.j42Hv2S05725@unix-os.sc.intel.com>

gcc 3.4.3 kicks out this warning: convert-cache.c: In function `write_subdirectory': convert-cache.c:102: warning: field precision is not type int (arg 4)

Signed-off-by: Tony Luck <tony.luck@intel.com>
---

--- k/convert-cache.c +++ l/convert-cache.c

@@ -99,7 +99,7 @@ static int write_subdirectory(void *buff
 			continue;
 		}
 
-		newlen += sprintf(new + newlen, "%o %.*s", S_IFDIR, slash - path, path);
+		newlen += sprintf(new + newlen, "%o %.*s", S_IFDIR, (int)(slash - path), path);
 		new[newlen++] = 0;
 		sha1 = (unsigned char *)(new + newlen);
 		newlen += 20;
Message 1 of 1 in “Fix warning in convert-cache”
  1. Fix warning in convert-cachetony.luck@intel.com, May 2, 2005

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.