On 8 February 2010 c. 23:50:53 Philip Guenther wrote: > 2010/2/8 Vadim Zhukov <persg...@gmail.com>: > > Thank you for your attention. And sorry, but I think that your > > version is wrong: in case of only one "X" you'll have "tries" set to > > 1 instead of NUM_CHARS. > > <sigh> > > Time to write some regress tests for mktemp obviously. Do you happen > to have a program reliably demonstrates the original buffer underrun > problem? (I couldn't get mktemp(1) to crash, but perhaps you have > combination of arguments, options, and (perhaps) /etc/malloc.conf > flags that does the trick every time?)
Looks like I was just lucky. :) I do not use malloc.conf. And mktemp(1) failed for me only sometimes (I'm using it for generating passwords: "mktemp XXXXXXXXXX"). After a few crashes I realized that it hurts me too much... Do not remember what snapshot it was, though, but it was definitely something from 2009. I'll try to write some regression tests, if you wish - never did this before, but I have some spare time now. -- Best wishes, Vadim Zhukov A: Because it messes up the order in which people normally read text. Q: Why is top-posting such a bad thing? A: Top-posting. Q: What is the most annoying thing in e-mail?