patch-pcbnew_class_module_cpp 693 B

12345678910111213
  1. $OpenBSD: patch-pcbnew_class_module_cpp,v 1.2 2011/05/03 18:31:14 jasper Exp $
  2. --- pcbnew/class_module.cpp.orig Sat Aug 21 11:49:32 2010
  3. +++ pcbnew/class_module.cpp Sat Aug 21 11:50:03 2010
  4. @@ -840,7 +840,7 @@ void MODULE::DisplayInfo( WinEDA_DrawFrame* frame )
  5. if( flag ) // Display last date the component was edited( useful in Module Editor)
  6. {
  7. time_t edit_time = m_LastEdit_Time;
  8. - strcpy( Line, ctime( &edit_time ) );
  9. + strlcpy(Line, ctime((time_t*) &edit_time), sizeof(Line));
  10. strtok( Line, " \n\r" );
  11. strcpy( bufcar, strtok( NULL, " \n\r" ) ); strcat( bufcar, " " );
  12. strcat( bufcar, strtok( NULL, " \n\r" ) ); strcat( bufcar, ", " );