Skip to content

Commit 5995d3c

Browse files
committed
Drop seemingly unnecessary Windows code handling
1 parent c4a8c2d commit 5995d3c

File tree

1 file changed

+0
-15
lines changed

1 file changed

+0
-15
lines changed

ext/dba/dba.c

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -660,27 +660,12 @@ static void php_dba_open(INTERNAL_FUNCTION_PARAMETERS, bool persistent)
660660
* when the lib opens the file it is already created
661661
*/
662662
file_mode = "r+b"; /* read & write, seek 0 */
663-
#ifdef PHP_WIN32
664-
if (!need_creation) {
665-
lock_file_mode = "r+b";
666-
} else
667-
#endif
668663
lock_file_mode = "a+b"; /* append */
669664
} else {
670-
#ifdef PHP_WIN32
671-
if (!need_creation) {
672-
file_mode = "r+b";
673-
} else
674-
#endif
675665
file_mode = "a+b"; /* append */
676666
lock_file_mode = "w+b"; /* create/truncate */
677667
}
678668
} else {
679-
#ifdef PHP_WIN32
680-
if (!need_creation) {
681-
file_mode = "r+b";
682-
} else
683-
#endif
684669
file_mode = "a+b";
685670
}
686671
/* In case of the 'a+b' append mode, the handler is responsible

0 commit comments

Comments
 (0)