Develop and Download Open Source Software

Browse Subversion Repository

Diff of /trunk/ttssh2/ttxssh/hosts.c

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

revision 3143 by maya, Mon Sep 1 05:13:11 2008 UTC revision 3144 by maya, Wed Sep 3 17:05:44 2008 UTC
# Line 47  See LICENSE.TXT for the license. Line 47  See LICENSE.TXT for the license.
47  #include <io.h>  #include <io.h>
48  #include <errno.h>  #include <errno.h>
49  #include <sys/stat.h>  #include <sys/stat.h>
50    #include <direct.h>
51    
52  static HFONT DlgHostsAddFont;  static HFONT DlgHostsAddFont;
53  static HFONT DlgHostsReplaceFont;  static HFONT DlgHostsReplaceFont;
# Line 1042  static void delete_different_key(PTInstV Line 1043  static void delete_different_key(PTInstV
1043          else {          else {
1044                  Key key; // 接続中のホストのキー                  Key key; // 接続中のホストのキー
1045                  int length;                  int length;
1046                  char filename[L_tmpnam];                  char filename[MAX_PATH];
1047                    char tmp[L_tmpnam];
1048                  int fd;                  int fd;
1049                  int amount_written = 0;                  int amount_written = 0;
1050                  int close_result;                  int close_result;
# Line 1050  static void delete_different_key(PTInstV Line 1052  static void delete_different_key(PTInstV
1052                  char buf[FILENAME_MAX];                  char buf[FILENAME_MAX];
1053    
1054                  // 書き込み一時ファイルを開く                  // 書き込み一時ファイルを開く
1055                  tmpnam(filename);                  _getcwd(filename, sizeof(filename));
1056                    tmpnam_s(tmp,sizeof(tmp));
1057                    strcat_s(filename, sizeof(filename), tmp);
1058                  fd = _open(filename,                  fd = _open(filename,
1059                            _O_CREAT | _O_WRONLY | _O_SEQUENTIAL | _O_BINARY | _O_TRUNC,                            _O_CREAT | _O_WRONLY | _O_SEQUENTIAL | _O_BINARY | _O_TRUNC,
1060                            _S_IREAD | _S_IWRITE);                            _S_IREAD | _S_IWRITE);

Legend:
Removed from v.3143  
changed lines
  Added in v.3144

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