Changeset 7460 for lang/c

Show
Ignore:
Timestamp:
03/04/08 15:36:24 (5 years ago)
Author:
frsyuki
Message:

lang/c/partty: fixed archive path

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • lang/c/partty/trunk/server.cc

    r7380 r7460  
    347347                        archive_base_dir << m_archive_dir; 
    348348 
    349                         archive_base_dir << '/' << tmp->tm_year + 1900; 
     349                        archive_base_dir << '/' 
     350                                << std::setw(4) << std::setfill('0') << (tmp->tm_year + 1900); 
    350351                        mkdir(archive_base_dir.str().c_str(), 0755); 
    351352 
     
    358359                        mkdir(archive_base_dir.str().c_str(), 0755); 
    359360 
    360                         archive_base_dir << '/'; 
     361                        archive_base_dir << '/' 
     362                                << std::setw(2) << tmp->tm_hour << '-' 
     363                                << std::setw(2) << tmp->tm_min  << '-' 
     364                                << std::setw(2) << tmp->tm_sec  << '-'; 
    361365 
    362366                        std::ostringstream record_info_path;