Bug 16834 - On Windows _read() should be used instead of read()?
Summary: On Windows _read() should be used instead of read()?
Status: RESOLVED FIXED
Alias: None
Product: dbus
Classification: Unclassified
Component: core (show other bugs)
Version: unspecified
Hardware: x86 (IA32) Windows (All)
: medium normal
Assignee: Havoc Pennington
QA Contact: John (J5) Palmieri
URL:
Whiteboard:
Keywords: patch
Depends on: 16788
Blocks:
  Show dependency treegraph
 
Reported: 2008-07-24 06:04 UTC by Sunil Mohan Adapa
Modified: 2009-12-14 00:35 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments
the simple change that worked for me (470 bytes, patch)
2008-07-24 06:04 UTC, Sunil Mohan Adapa
Details | Splinter Review

Description Sunil Mohan Adapa 2008-07-24 06:04:41 UTC
Created attachment 17854 [details] [review]
the simple change that worked for me

I am using a debug version of DBUS from trunk on Windows compiled with msvc from Visual Studio 2005 Express Edition. I kept the following assertion:

---------------------------
Microsoft Visual C++ Debug Library
---------------------------
Debug Assertion Failed!

Program: ...
File: read.c
Line: 86

Expression: (_osfile(fh) & FOPEN)

For information on how your program can cause an assertion
failure, see the Visual C++ documentation on asserts.

(Press Retry to debug the application)
---------------------------
Abort   Retry   Ignore   
---------------------------

This page (http://msdn.microsoft.com/en-us/library/ms235412(VS.80).aspx) says the _read() should be used instead of read() and it worked for me.
Comment 1 Havoc Pennington 2008-07-24 07:59:14 UTC
See also bug #16788
Comment 2 Sunil Mohan Adapa 2009-12-14 00:35:21 UTC
Fixed in head with dbus4win merges.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.