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

Re: libusb & PATH_MAX



On Fri, May 22, 2009 at 02:56:44PM +0200, Samuel Thibault wrote:
> Carl Fredrik Hammar, le Fri 22 May 2009 14:43:39 +0200, a écrit :
> 
> > But why not wait until they actually break?
> 
> Depending on the solution we adopt, the break may be memory overflows,
> which are hard to understand where they come from. Here, the filename
> string could in theory be 2 bytes long, and thus the application using
> sizeof(filename) would overflow. We can make sure the filename is at
> least sizeof(void*) though.

Ah, you're right, I missed that one.  Luckily, you're fix seems
reasonable.

Well, it seems my two cents are all used up.  It will be interesting to
see which solution you finally go for.

Regards,
  Fredrik


Reply to: