Develop and Download Open Source Software

Browse CVS Repository

Diff of /malonnote/mnModel.cpp

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph | View Patch Patch

revision 1.12 by maloninc, Sat Aug 13 02:00:29 2005 UTC revision 1.13 by maloninc, Sat Aug 13 06:12:05 2005 UTC
# Line 287  void WikiData::modSubject(wxString* newS Line 287  void WikiData::modSubject(wxString* newS
287          sprintf(newFullPath, "%s/%s", (const char*)dataDirName->mb_str(), (const char*)fileName->mb_str());          sprintf(newFullPath, "%s/%s", (const char*)dataDirName->mb_str(), (const char*)fileName->mb_str());
288    
289          if((fp = fopen(newFullPath, "r")) == NULL) {          if((fp = fopen(newFullPath, "r")) == NULL) {
290                  rename(oldFullPath, newFullPath);                  if(rename(oldFullPath, newFullPath) < 0) wxLogMessage(wxT("rename error: errno=[%d]"), errno);
291          }          }
292          else if(strcmp(oldFullPath, newFullPath)){          else if(strcmp(oldFullPath, newFullPath)){
293                  wxLogMessage(wxT("File has already exist. [%s]"), fileName->c_str());                  wxLogMessage(wxT("File has already exist. [%s]"), fileName->c_str());
294                  fclose(fp);                  fclose(fp);
295          }          }
296            else {
297                    fclose(fp);
298            }
299    
300          delete oldSubject;          delete oldSubject;
301          delete oldFileName;          delete oldFileName;

Legend:
Removed from v.1.12  
changed lines
  Added in v.1.13

Back to OSDN">Back to OSDN
ViewVC Help
Powered by ViewVC 1.1.26