lkml.org 
[lkml]   [1999]   [Apr]   [21]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectWhy is kfree_s useful?
From
Date
As the subject says, why is kfree_s useful in its current state? Sure, 
it's nice to have protection against trying to free the wrong memory,
but is quietly not freeing memory really the best way to do this?

It seems to me that if code has the sort of bugs that kfree_s is
supposed to protect against, a slow core leak due to kfree_s quietly
not freeing memory isn't really that much better than crashing
immediately. At least in the second case you see where things went
wrong. Wouldn't a a "hey idiot, you tried to free memory with a bad
size" sort of warning be best?


--nat

--
nat lanza --------------------- research programmer, parallel data lab, cmu scs
magus@cs.cmu.edu -------------------------------- http://www.cs.cmu.edu/~magus/
there are no whole truths; all truths are half-truths -- alfred north whitehead

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:51    [W:0.039 / U:0.372 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site