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

Re: [PATCH] cast pid_t to long for printing

From
Junio C Hamano <junkio@cox.net>
Date
Jun 26, 2006, 09:26 UTC
Message-ID
<7vr71ci7yt.fsf@assigned-by-dhcp.cox.net>
In-Reply-To
<20060626082606.GC3646@informatik.uni-freiburg.de>
Uwe Zeisberger <zeisberg@informatik.uni-freiburg.de> writes:
> While fixing daemon.c, I saw that there is a call to syslog using %d for
> pid_t, too.  I fixed that in the same way without further testing and
> manual reading. I assume that's OK.

Is anybody using pid_t that is wider than int? IOW, I wonder if it would make more sense to use "%d" with casting to int.

Previous: Uwe ZeisbergerNext: Uwe Zeisberger
Message 5 of 6 in “Solaris 8”
  1. Uwe ZeisbergerJun 26, 2006
  2. include signal.h for prototype of signal()Uwe Zeisberger, Jun 26, 2006
  3. Uwe ZeisbergerJun 26, 2006
  4. cast pid_t to long for printingUwe Zeisberger, Jun 26, 2006
  5. Junio C HamanoJun 26, 2006
  6. Uwe ZeisbergerJun 26, 2006

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.