Any updates on this set of patches? On Sat, Mar 22, 2014 at 12:05 PM, Yousong Zhou <[email protected]> wrote: > Hi, Jure. > > On 22 March 2014 18:02, Jure Grabnar <[email protected]> wrote: >> Hi, >> >> thank you for your feedback, Darshit, Yousong! >> >> I reverted magic number back to its original state ('tmp2'), because it >> should >> be there (I overlooked that 'tmp' variable is changed in the very next >> statement). >> >> Duplicated line is removed. >> >> I also changed resource->type to point at dynamic memory. > > + if (type) > + { > + resource->type = malloc (strlen (type)); > + sprintf(resource->type, type); > + } > > xstrdup() is better because that is how existing code does it. And > you may want to know that using a variable as the format string is not > a good practice for secure code. > > yousong > >> >> They say third's time's the charm. :) I hope it's ok now. >> >> Regards, >> >> >> Jure Grabnar >> >>
-- Thanking You, Darshit Shah
