Develop and Download Open Source Software

Browse Subversion Repository

Diff of /trunk/teraterm/ttpcmn/ttcmn.c

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

revision 9463 by zmatsuo, Thu Oct 14 14:51:10 2021 UTC revision 9466 by zmatsuo, Thu Oct 14 14:51:37 2021 UTC
# Line 109  void WINAPI CopyTTSetToShmem(PTTSet ts) Line 109  void WINAPI CopyTTSetToShmem(PTTSet ts)
109          memcpy(&pm->ts, ts, sizeof(TTTSet));          memcpy(&pm->ts, ts, sizeof(TTTSet));
110  }  }
111    
112    static wchar_t* GetLogDirW()
113    {
114            wchar_t *local_app_data;
115            wchar_t *log;
116            _SHGetKnownFolderPath(&FOLDERID_LocalAppData, 0, NULL, &local_app_data);
117            aswprintf(&log, L"%s\\%s", local_app_data, L"teraterm5");
118            free(local_app_data);
119            CreateDirectoryW(log, NULL);
120            return log;
121    }
122    
123  BOOL WINAPI StartTeraTerm(PTTSet ts)  BOOL WINAPI StartTeraTerm(PTTSet ts)
124  {  {
125          if (FirstInstance) {          if (FirstInstance) {
# Line 128  BOOL WINAPI StartTeraTerm(PTTSet ts) Line 139  BOOL WINAPI StartTeraTerm(PTTSet ts)
139          // if (FirstInstance) { の部分から移動 (2008.3.13 maya)          // if (FirstInstance) { の部分から移動 (2008.3.13 maya)
140          // 起動時には、共有メモリの HomeDir と SetupFName は空になる          // 起動時には、共有メモリの HomeDir と SetupFName は空になる
141          /* Get home directory (ttermpro.exeのフォルダ) */          /* Get home directory (ttermpro.exeのフォルダ) */
142            ts->ExeDirW = GetHomeDirW(hInst);
143            ts->LogDirW = GetLogDirW();
144          ts->HomeDirW = GetHomeDirW(hInst);          ts->HomeDirW = GetHomeDirW(hInst);
145          WideCharToACP_t(ts->HomeDirW, ts->HomeDir, _countof(ts->HomeDir));          WideCharToACP_t(ts->HomeDirW, ts->HomeDir, _countof(ts->HomeDir));
146          SetCurrentDirectoryW(ts->HomeDirW);          SetCurrentDirectoryW(ts->HomeDirW);

Legend:
Removed from v.9463  
changed lines
  Added in v.9466

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