Re: [PATCH] Don't crash if ai_canonname comes back as null

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> 
> On Apr 29, 2009, at 6:21 PM, Junio C Hamano wrote:
> 
> > Augie Fackler <durin42@xxxxxxxxx> writes:
> >
> >> Fixes a weird bug where git-daemon was segfaulting
> >> when started by sh(1) because ai_canonname was null.
> >> ---
> >> Fixed based on feedback.
> >
> > Hmm.
> >
> > I've been waiting for feedback to a patch proposed earlier in the same
> > area, which is <49F5BA55.3060606@xxxxxxxxxxxxxx> ($gmane/117670).  How
> > does this new one relate to it?
> 
> I can't comment much on the correctness of the code - my patch was the  
> minimal change to have it not crash.
> 
> The other patch also works for me to prevent the crash, and looks like  
> it might be a little more correct in terms of having a meaningful  
> hostname.

So, I wasn't CC'ed on the referenced patch ($gmane/117670), but it
seems to me that there might be value in actually looping over the
whole list of addrinfo results exactly in the case that it does
return a null canonical name for one of its addresses?  Perhaps an
inverse call to getnameinfo() is warranted too?

Sorry, I'm just not certain here.

jdl
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]