OLD | NEW |
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ | 1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ |
2 /* This Source Code Form is subject to the terms of the Mozilla Public | 2 /* This Source Code Form is subject to the terms of the Mozilla Public |
3 * License, v. 2.0. If a copy of the MPL was not distributed with this | 3 * License, v. 2.0. If a copy of the MPL was not distributed with this |
4 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ | 4 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ |
5 | 5 |
6 /* Windows 95 IO module | 6 /* Windows 95 IO module |
7 * | 7 * |
8 * Assumes synchronous I/O. | 8 * Assumes synchronous I/O. |
9 * | 9 * |
10 */ | 10 */ |
(...skipping 937 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
948 PRStatus | 948 PRStatus |
949 _PR_MD_LOCKFILE(PROsfd f) | 949 _PR_MD_LOCKFILE(PROsfd f) |
950 { | 950 { |
951 PRStatus rc = PR_SUCCESS; | 951 PRStatus rc = PR_SUCCESS; |
952 DWORD rv; | 952 DWORD rv; |
953 | 953 |
954 rv = LockFile( (HANDLE)f, | 954 rv = LockFile( (HANDLE)f, |
955 0l, 0l, | 955 0l, 0l, |
956 0x0l, 0xffffffffl ); | 956 0x0l, 0xffffffffl ); |
957 if ( rv == 0 ) { | 957 if ( rv == 0 ) { |
958 DWORD rc = GetLastError(); | 958 DWORD err = GetLastError(); |
| 959 _PR_MD_MAP_DEFAULT_ERROR(err); |
959 PR_LOG( _pr_io_lm, PR_LOG_ERROR, | 960 PR_LOG( _pr_io_lm, PR_LOG_ERROR, |
960 ("_PR_MD_LOCKFILE() failed. Error: %d", rc )); | 961 ("_PR_MD_LOCKFILE() failed. Error: %d", err )); |
961 rc = PR_FAILURE; | 962 rc = PR_FAILURE; |
962 } | 963 } |
963 | 964 |
964 return rc; | 965 return rc; |
965 } /* end _PR_MD_LOCKFILE() */ | 966 } /* end _PR_MD_LOCKFILE() */ |
966 | 967 |
967 PRStatus | 968 PRStatus |
968 _PR_MD_TLOCKFILE(PROsfd f) | 969 _PR_MD_TLOCKFILE(PROsfd f) |
969 { | 970 { |
970 PR_SetError( PR_NOT_IMPLEMENTED_ERROR, 0 ); | 971 PR_SetError( PR_NOT_IMPLEMENTED_ERROR, 0 ); |
(...skipping 392 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1363 info->creationTime = info->modifyTime; | 1364 info->creationTime = info->modifyTime; |
1364 } else { | 1365 } else { |
1365 _PR_FileTimeToPRTime(&findFileData.ftCreationTime, | 1366 _PR_FileTimeToPRTime(&findFileData.ftCreationTime, |
1366 &info->creationTime); | 1367 &info->creationTime); |
1367 } | 1368 } |
1368 | 1369 |
1369 return 0; | 1370 return 0; |
1370 } | 1371 } |
1371 /* ================ end of UTF16 Interfaces ================================ */ | 1372 /* ================ end of UTF16 Interfaces ================================ */ |
1372 #endif /* MOZ_UNICODE */ | 1373 #endif /* MOZ_UNICODE */ |
OLD | NEW |