cvs commit: src/sbin/sysctl sysctl.c

Joerg Sonnenberger joerg at crater.dragonflybsd.org
Tue Jan 11 15:37:21 PST 2005


joerg       2005/01/11 15:36:39 PST

DragonFly src repository

  Modified files:
    sbin/sysctl          sysctl.c 
  Log:
  Don't write the name of the sysctl to a temporary variable and truncate
  it on the '=' there. If the argument is actually longer than the buffer,
  this would result in a NULL reference. Instead, allocate the necessary
  buffer with alloca and copy the name part.
  
  Discovered-by: Suleiman Souhlal <ssouhlal at xxxxxxxxxxx>
  
  Revision  Changes    Path
  1.8       +22 -15    src/sbin/sysctl/sysctl.c


http://www.dragonflybsd.org/cvsweb/src/sbin/sysctl/sysctl.c.diff?r1=1.7&r2=1.8&f=u





More information about the Commits mailing list