Fossil

Check-in [27905725]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:found the cause of the crash!!!!
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | msvc-broken
Files: files | file ages | folders
SHA1:27905725de26d284a8e1f630ae190060ee44fdbe
User & Date: jan.nijtmans 2012-08-29 22:37:02
Context
2012-08-29
23:33
Allow no-op merges with the --force flag. Closed-Leaf check-in: d787bcd4 user: drh tags: msvc-broken
22:43
remaining part of [01a2f3a346] factor out the opendir() family of routines and provide portable alternatives, fossil_opendir() check-in: 4f9f0570 user: jan.nijtmans tags: trunk
22:37
found the cause of the crash!!!! check-in: 27905725 user: jan.nijtmans tags: msvc-broken
20:51
merge-mark (in order to make merging back msvc-broken to trunk easier) check-in: 2b5d6934 user: jan.nijtmans tags: msvc-broken
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to src/file.c.

578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
*/
void file_getcwd(char *zBuf, int nBuf){
#ifdef _WIN32
  char *zPwdUtf8;
  int nPwd;
  int i;
  wchar_t zPwd[2000];
  if( _wgetcwd(zPwd, sizeof(zPwd)-1)==0 ){
    fossil_fatal("cannot find the current working directory.");
  }
  zPwdUtf8 = fossil_unicode_to_utf8(zPwd);
  nPwd = strlen(zPwdUtf8);
  if( nPwd > nBuf-1 ){
    fossil_fatal("pwd too big: max %d\n", nBuf-1);
  }







|







578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
*/
void file_getcwd(char *zBuf, int nBuf){
#ifdef _WIN32
  char *zPwdUtf8;
  int nPwd;
  int i;
  wchar_t zPwd[2000];
  if( _wgetcwd(zPwd, sizeof(zPwd)/sizeof(zPwd[0])-1)==0 ){
    fossil_fatal("cannot find the current working directory.");
  }
  zPwdUtf8 = fossil_unicode_to_utf8(zPwd);
  nPwd = strlen(zPwdUtf8);
  if( nPwd > nBuf-1 ){
    fossil_fatal("pwd too big: max %d\n", nBuf-1);
  }