Free Downloads, Community Forum,
FAQs and Developer Resources


Make /Tools Your Home | Link to us

Today's posts | Posts since last visit | Most Active Topics

All Forums Register Login Search Subscriptions My Profile Inbox
Tool Warehouse FAQs Resources Help Member List Address Book Logout

A gem from Xlib.h

 
Logged in as: Guest
Users viewing this topic: none
  Printable Version
All Forums >> [SFU / Interix / SUA Technology] >> Interix Advanced Forum >> A gem from Xlib.h Page: [1]
Login
Message << Older Topic   Newer Topic >>
A gem from Xlib.h - Nov. 15, '05, 3:40:47 AM   
jon493

 

Posts: 56
Joined: Oct. 14, '05,
Status: offline
I came across this while porting a really old version of linux xloadimage (sorry in advance). It could be a problem with xloadimage, but it sure looked odd, so here it is. The extracts are from the files mentioned -- even the comment is quoted.

</usr/include/sys/types.h>
typedef unsigned short wchar_t;

</usr/X11/include/X11/Xlib.h>
/* replace this with #include or typedef appropriate for your system */
typedef unsigned long wchar_t;

In my humble opinion, unsigned short seems a more likely candidate (as it is 2 bytes -- the same as the real wchar_t)
Post #: 1
RE: A gem from Xlib.h - Nov. 15, '05, 5:58:29 AM   
Rodney

 

Posts: 3142
Joined: Jul. 9, '02,
From: /Tools lab
Status: online
Just comment out the "wchar_t" definitions.
Instead include <wchar.h> which has the real system definition for wchar_t.

It looks like the code might have been trying to workaround a bug or oddity in
a particular version of X11's Xlib.h. I expect that with X11R6 it's cleared up.

(in reply to jon493)
Post #: 2
RE: A gem from Xlib.h - Nov. 16, '05, 7:17:23 AM   
jon493

 

Posts: 56
Joined: Oct. 14, '05,
Status: offline
The typedefs are not from the xloadimage package. They are form the SFU system headers from the files mentioned in <>

(in reply to Rodney)
Post #: 3
Page:   [1]
All Forums >> [SFU / Interix / SUA Technology] >> Interix Advanced Forum >> A gem from Xlib.h Page: [1]
Jump to:





New Messages No New Messages
Hot Topic w/ New Messages Hot Topic w/o New Messages
Locked w/ New Messages Locked w/o New Messages
 Post New Thread
 Reply to Message
 Post New Poll
 Submit Vote
 Delete My Own Post
 Delete My Own Thread
 Rate Posts


Search All Forums -

Advanced search


SPONSORS



Forum Software © ASPPlayground.NET Advanced Edition 2.5 ANSI

0.031