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

Re: [PATCH v2] daemon.c: avoid accessing ss_family member of struct sockaddr_storage

From
Martin Storsjö <martin@martin.st>
Date
Mar 16, 2010, 07:52 UTC
Message-ID
<alpine.DEB.2.00.1003160949270.29993@cone.home.martin.st>
In-Reply-To
<Ulrh6ePYHqfB90btctT3EMJiuUz4wjLndvupvp0xJR1sBAao-hZxS0PI6-IxWscYhjaEno7FzgY@cipher.nrlssc.navy.mil>
On Mon, 15 Mar 2010, Brandon Casey wrote:
Show 7 quoted lines
> On 03/15/2010 04:37 PM, Martin Storsjö wrote:
> > Coming to think about it, would it simplify the code even more if the 
> > function were to take a const struct sockaddr* as a parameter instead? 
> > That would, on the other hand, require more casts where it's called, 
> > though...
> 
> How about this.
Yes, this looks neat!
Acked-by: Martin Storsjö <martin@martin.st>
// Martin
Previous: Brandon CaseyNext: Gary V. Vaughan
Message 12 of 17 in “struct sockaddr_storage->ss_family is not portable”
  1. 5/5 struct sockaddr_storage->ss_family is not portableGary V. Vaughan, Mar 11, 2010
  2. Martin StorsjöMar 11, 2010
  3. Gary V. VaughanMar 12, 2010
  4. Martin StorsjöMar 12, 2010
  5. daemon.c: avoid accessing ss_family member of struct sockaddr_storageBrandon Casey, Mar 15, 2010
  6. Jeff KingMar 15, 2010
  7. Martin StorsjöMar 15, 2010
  8. Brandon CaseyMar 15, 2010
  9. Gary V. VaughanApr 25, 2010
  10. Martin StorsjöMar 15, 2010
  11. daemon.c: avoid accessing ss_family member of struct sockaddr_storageBrandon Casey, Mar 15, 2010
  12. Martin StorsjöMar 16, 2010
  13. Gary V. VaughanApr 25, 2010
  14. Martin StorsjöApr 25, 2010
  15. Gary V. VaughanApr 26, 2010
  16. Jeff KingMar 11, 2010
  17. Brandon CaseyMar 11, 2010

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.