# flock() php_flock() compile problems

- Thread: https://externals.io/message/28696
- Original archive: https://news-web.php.net/php.internals/28696
- Started by Frank M. Kromann on 2007-04-06T04:19:45+00:00
- Messages: 2
- Reply by email to internals@lists.php.net
- More for agents: search with https://externals.io/search.md?q={query} · JSON API at https://externals.io/api · documentation at https://externals.io/llms.txt

---

## #28696 — Frank M. Kromann — 2007-04-06T04:19:45+00:00

URL: https://externals.io/message/28696#28696

Hello Everyone,

I hope I'm not too far off here but getting rid of flock.c in
win32\build\config.w32 an adding flock_compat to ext\standard\config.w32
seams to solve the compile problems, at least in the 5.2 branch.

- Frank

---

## #28697 — Rasmus Lerdorf — 2007-04-06T04:26:22+00:00

URL: https://externals.io/message/28696#28697 · In reply to: #28696

Frank M. Kromann wrote:
> Hello Everyone,
> 
> I hope I'm not too far off here but getting rid of flock.c in
> win32\build\config.w32 an adding flock_compat to ext\standard\config.w32
> seams to solve the compile problems, at least in the 5.2 branch.

Rob tracked it down to the fact that it was using stdio.  I hadn't
realized that.  So, the fix is to use VCWD_OPEN_MODE instead of FOPEN
and a write() instead of the fprintf.

-Rasmus
