HDTenEightyP/NetNews huggingface dataset:
From: os2man@panix.com (Larry Salomon Jr.)
Newsgroups: comp.os.os2.programmer
Subject: Re: fopen(f,"r") vs fopen(f,"rb") what's the diff?
Date: 27 Jul 92 22:25:31 GMT
Organization: PANIX Public Access Unix, NYC

In <1992Jul25.175848.29166@unixg.ubc.ca> ochealth@unixg.ubc.ca (ochealth) writes:



>A number of UNIX programs I have ported to OS/2 using emx or gcc
>choke on binary files, unless I modify them.

>for example:
>f = fopen(name,"r") must be changed to f=fopen(name,"rb")
>etc.

>I was wondering just what happens when you don't open as binary.
>Will it return EOF when it sees ^Z or what?

>This is sort of troubling to me, since EMX is desing to make porting UNIX easier

>Was fopen changed to make it more compatible with OS/2 or what. From what I've
>read "r" and "rb" are handled the same in UNIX.

"r" and "rb" are a world apart, although the difference is slight.  "Text mode"
implies that CR-LF pairs are translated to LF on reads and vice-versa on 
writes.  This is due to the hardware, I believe, requiring the CR and LF
to perform a "new line" operation.  Additionally - and I could be wrong here -
text mode does return EOF when Ctrl-Z is encountered, while binary mode does
not.

-- 
Cheers,
Q
-----------------------------------------------------------------------
"If you still choose not to decide,   | "My other account is in the
From: ts@cup.portal.com (Tim W Smith)
Newsgroups: comp.os.os2.programmer
Subject: Re: Win NT Dev, Conf. Report
Date: Tue, 21 Jul 92 07:33:55 PDT
Organization: The Portal System (TM)
  <pathak-130792094456@virtual.mitre.org>

> My biggest concern here has been the stability of the kernel.  While the
> beta kernel looks good, you really don't know how well it works.  Before
> somebody posts something about how it is a microkernel and thus small and
> easy to write well, let me point out that both NeXT and OSF spend a huge
> amount of time testing and debugging the Mach microkernel.  From what I
> understand, the Mach kernel is now very stable but if it took time and
> people using in commercial situtations before all the bugs were found and
> taken out.

Yeah, but compared to the number of people who develop for Microsoft
OSes, the number of Mach developers is insignificant.  If Microsoft
can get a significant fraction of their developers to participate in
an NT beta, they should be able to get kernel stability before a general
release with no problem (assuming that any lack of kernel stability is
due to implementation bugs rather than design flaws).

They can do what Apple did with System 7 for the Mac.  Apple made sure
that alphas and betas of System 7 where widespread in the developer
community.  They had many thousands of qualified alpha and beta testers.

A system like Mach is not going to get this kind of testing until it
gets released.

--Tim Smith
From: rjm@dciem.dciem.dnd.ca (Robert J. Manley)
Newsgroups: comp.os.os2.programmer
Subject: non-emx gcc with IBM toolkit
Date: 24 Jul 92 19:39:24 GMT
Distribution: na
Organization: NTT Systems Inc., Toronto, Canada


Hopefully a simple question for you OS/2 2.00 gcc (non-emx) gurus.

I want to use this version of gcc with the IBM developer's toolkit.  I have
the icc2gcc file but it looks like it is relevant only for the emx version
(it is very nice though).  In the docs it does mention the neccessary trivial
defines (e.g. _Seg16) which allow the compiler to successfully parse the
include files.  Furthermore, I have overridden the default "C++" calling
context via the explicit language specification of

	extern "C"
	{
		#include <os2.h>
	}

The problem I am having is that the os2386 libs seem to have ASM symbols
i.e. no underscore and case insensitive.  The latter I can live with but the
lack of underscores is producing unresolved externals which I can't seem to
get around.  Now the question is, can I stop gcc from prepending underscores
to "C" functions (already tried -mno-underscores) or alternatively specify
another language (tried "ASM" and a bunch of others) to accomplish this.

Thanks in advance.

Robert.
-- 
# Robert J. Manley,  rjm@dretor.dciem.dnd.ca		#
# #include <std_disclaimer.hpp>				#
# NTT Systems Inc., Toronto, Ontario, CANADA		#
# Long Live Lint (C++ long ints that is!)		#
Newsgroups: comp.os.os2.programmer
From: lemieux@eecg.toronto.edu (Guy Gerard Lemieux)
Subject: Re: The expensive IBM doc set
Date: 31 Jul 92 14:38:17 GMT

orville%weyrich@tnet.com (Orville R. Weyrich) writes:

I'm sure many people look at the list and wonder which to buy.  In
my experience with the 1.2 toolkit, the books listed as "online" were
the ones I used almost exclusively.  I found that the online version
was handy, but the books were even better (you learn a lot by page
flipping past other function calls and glancing at them).  Here are
my opinions (based upon OS/2 1.2!!) on what is needed.  Perhaps others
would be willing to share their opinions as well.

If you want to buy a(ny) subset of the docs, I'd recommend at least:

Control Program Programming ...		10G-6263	Y	$25.00
Presentation Manager ... Vol. I		10G-6264	Y	$35.00
Presentation Manager ... Vol. II	10G-6265	Y	$35.00
Presentation Manager ... Vol. III	10G-6272	Y	$35.00

I haven't done 2.0-specific development yet, and haven't seen this,
but it might be somewhat necessary:

System Object Model			10G-6309	Y	$9.00

The CUA books were 'bed-time reading' and not really reference type
books, but still consultable.  I recommend them if you are serious
about putting out CUA-compliant stuff, even though you probably won't
use them very much:

SAA CUA Guide to User Interface Design	10G-6270		$10.00
SAA CUA Advanced Interface Design ...	10G-6271		$18.25

Obviously, if you are doing some sort of device driver stuff these
would be useful:

Physical Device Driver ...		10G-6266		$30.00
Virtual Device Driver ...		10G-6310		$10.00
Presentation Driver ...			10G-6267		$25.00

If you are new to PM programming, you would probably want these as
supplements to Petzold's book (they decribe how OS/2 and PM work,
and how you should write your programs--I think they have some example
code and describe it):

Programming Guide Volume I		10G-6261		$15.00
Programming Guide Volume II		10G-6494		$25.00
Programming Guide Volume III		10G-6495		$15.00

The REXX books I remember from the 1.2 toolkit were almost useless to me.
I did do some REXX and REXX<->C interface stuff, and even then they were
of little use:

... REXX Reference			10G-6268		$15.00
... REXX User's Guide			10G-6269		$10.00

I guess you may need this for doing IPF-style documentation:

Information Presentation Facility ...	10G-6262	Y	$15.00

And I don't remember what this was about:

Application Design Guide		10G-6260		$15.00


Sorry, but it has been a year since I did OS/2 development, and my
memory is a bit foggy.  Feel free to make corrections or supplement
what I have said.

Guy
--
Guy Lemieux                (416) 516-8934             224 Lippincott St.
Engineering Science 9T3    lemieux@ecf.toronto.edu           Toronto, ON
University of Toronto      lemieux@eecg.toronto.edu              M5S 2P5
From: serge@concour.cs.concordia.ca (Serge Lalonde)
Newsgroups: comp.os.os2.programmer
Subject: X, Xt & Motif Libraries in OS/2
Summary: Where are they ?
Keywords: X Motif
Date: 26 Jul 92 03:54:39 GMT
Organization: Concordia University, Montreal, Quebec


Hi all.

This is a question that I have been dying to ask, but was hoping that
someone would beat me to it (no such luck). So here goes.


Where can I find Xlib, Xt & Motif libraries for OS/2 ?????


I called IBM, and after a few "that isn't my department, I'll switch you
to such-and-such", I finally found out that IBM does distribute an X
server for OS/2 as an option in their TCP/IP package. But what I really
need is the ability to simply recompile my X applications using these
libraries, and have them have a similar appearance, without having to
rewrite the entire user interface.

I'd really appreciate ANY kind of response as to my alternatives in
this area. Responses can be posted here, or mailed to me and I will
post a summary if anyone is interested.

Thanks.

My e-mail is: uunet!matrox!infohp!serge (at work)
          or: serge@cs.concordia.ca (at school)

--
Serge Lalonde
serge@concour.cs.concordia.ca
A wise man once said... Don't quote wise men - they're not as wise as you think.
Newsgroups: comp.os.os2.programmer
From: gkm@cbnewsh.cb.att.com (gary.k.mc nees)
Subject: TCP/IP LaMail Bugs
Organization: AT&T
Distribution: usa
Date: Thu, 30 Jul 1992 14:21:41 GMT

I have the latest version of IBM TCP/IP and have found what I think
are a couple of bugs in the LaMail 2.2 program. If one marks several
files in a folder and then tries to either move them or delete them
only one gets moved or deleted. Also I have found that mail items some-
times show in a folder but are actually not there. When I try to open
them the bottom information line in the note window says that an error
occurred attempting to open the note. This occurs even after I have
just done a refresh on the folder, i.e. if the note is not there then
its title shouldn't show up in the folder.

I hope this gets to someone who is interested at IBM.

Gary McNees gkm@corvette.ho.att.com
From: daveb@netcom.com (Dave Briccetti)
Newsgroups: comp.os.os2.programmer
Subject: Re: Which message on Font Change.
Date: 26 Jul 92 18:07:56 GMT
Article-I.D.: netcom.n2kmz5m.daveb
Organization: Netcom - Online Communication Services  (408 241-9760 guest)

sl31+@andrew.cmu.edu (Stephen M. Lacy) writes:
: 
: 	I've been typing in some more of the sample progrmams from the book
: that I recently got, and my question is this:  I'm using the function
: GpiCharStringAt, and just for the hell of it, I brought up the "Font
: Palette" and dragged a different font to my window to see what would
: happen.  There was no visible change, but if I then "invalidated" some
: portion of the window, that portion, when refreshed, came back in the
: new font.  My question is:  What message is sent to my window procedure
: when I drag a new font to the window?  I tried a couple of the more
: obvious ones, I don't remember their names right now, something about
: SYSVALUE and COLORCHANGE, I'm not sure.  Also, I'm assuming that this is
: the way these features work, if they're not, let me know what the
: standard way of dealing with them is.  I've also tried dragging a new
: color to the window, and it seems to make no difference at all.  Is
: there a message that also goes with a color change?  Some pseudo-code
: would also be helpful.  Thanks.  
: 
Did you look at WM_SETWINDOWPARAMS?  The WNDPARAMS structure contains
Presentation Parameter length and data pointer elements.

-- 

Dave Briccetti, Owner, Dave Briccetti & Associates
OS/2 Developer/Consultant
P.O. Box 1713
Lafayette, CA  94549-7013
Newsgroups: comp.os.os2.programmer
From: cjensen@ampex.com (Colin Jensen)
Subject: Re: EMX library bug.
Organization: Ampex Corporation, Redwood City CA
Date: Wed, 22 Jul 1992 18:53:06 GMT

In article <ReiBoB5w164w@dvss.UUCP> dvss!jtroy@udel.edu (Jay Troy) writes:
>I think I've discovered an EMX library bug.  The standard library function
>strtok causes an access violation in every combination that I've tried.  The
>following simple C program illustrates this problem:

>    char *ch = "3.4 4.1";
>    strcpy(temp, strtok(ch," "));

I don't know anything about EMX, but your code is certainly problematic.
A C compiler is free to store strings constants like "3.4 4.1" in 
read-only memory [hence their name].  Since strtok will try to write 
into that memory, an access violation should be expected.

To be portable, you need to copy that string either into an automatic variable
or copy it into some malloc'ed memory.

Under UNIX, you can pass gcc the option -fwritable-strings to tell gcc you
really want to be able to write into string constants.  Perhaps this would
solve your problem with EMX.
-- 
Colin Jensen (cjensen@ampex.com)
Newsgroups: comp.os.os2.programmer
From: pathak@mitre.org (Heeren Pathak)
Subject: Re: Can someone at IBM please explain why developers should develop for OS/2?
Followup-To: comp.os.os2.programmer
Organization: Mitre Corporation
Date: Wed, 29 Jul 1992 19:53:22 GMT

In article <1992Jul29.154428.12738@njitgw.njit.edu>, dic5340@hertz.njit.edu
(David Charlap) wrote:
> 
> In article <1992Jul28.021436.2865@hellgate.utah.edu> brian%jensen.cs.utah.edu@cs.utah.edu (Brian Sturgill) writes:
> >Why does IBM charge so much for the hardcopy manual set?
> 
> Perhaps because it consists of 17 large volumes?
> 

Fine.  Then do what MS did with NT and put the manuals on-line on a CD. 
Allow people to buy the manuals separately.  This will bring down the price
to a more reasonable level.  I would love to develop code for OS/2 but
since the money would be out of my own pocket, I am waiting until Borland
release their complier.

> >How can anyone possibly justify a >$800 price tag?
> 
> Right now, it's only ~$300.  I'd be shocked if dealers didn't discount
> it to about $600 or less.  $800 will be a list price.

Since MS is giving the NT CD's for $69, ~$300 is a bit high.  IBM needs to
get software out for OS/2.  Sure they have "convinced" the big companies to
release OS/2 products (supposedly they funded the development effort) but
they really haven't done much for the small developers.

-------------------------------------------------------------------------
Heeren Pathak                      | Millions long for immortality who do 
pathak@mitre.org                   | not know what to do with themselves
Mitre Corporation                  | on a rainy Sunday afternoon.
(617) 271-7465                     |	               	-- Susan Ertz
-------------------------------------------------------------------------
Disclaimer: Mine not Mitre's.
From: conrad@pico.OZ (Conrad Drake)
Newsgroups: comp.os.os2.programmer
Subject: Mid-pipe abort Handling?
Date: 28 Jul 92 01:32:48 GMT
Reply-To: conrad@pico.qpsx.oz.au
Organization: QPSX Communications
X-Newsreader: Tin 1.1 PL4

Hi,
   a question OS2 gurus from a friend. In a make file he's used the
following construct

findfiles | prog1 | prog2

Now, the piping operation only returns the status of prog2.  Is there a
way of accessing the return status of the other piped processes? 

At the moment he's having to pass information along through prog1 &
prog2, which is unsatisfactory.

Thanks in anticipation,

Conrad DRake
---
"There's something stirring in my loins and it isn't the spirit of Jesus"
                - Helen Razor, JJJ announcer, 1992.

Email: conrad@pico.qpsx.oz.au
Snail: QPSX Communications, Private Bag 24, West Perth 6005, Australia. 
Numbers:(ph) +61 9 324 1641, (fx) +61 9 321 2984 (dod) 0604

Newsgroups: comp.os.os2.programmer
From: harris@garfield.catt.ncsu.edu (Michael Harris)
Subject: Re: Problem with checkbox
Organization: North Carolina State University
Distribution: usa, local
Date: Thu, 30 Jul 1992 00:42:30 GMT

ezeller@iiic.ethz.ch (Emil Johann Zeller) writes:

>MRESULT ClientWinProc(HWND hwnd, USHORT msg, MPARAM mp1,
>           MPARAM mp2)
>{
>  HWND hwndControl;
   ^^^^^^^^^^^^^^^^

This is your problem. You are aware of the fact that EVERY time your window
proceedure gets a message, these variables are created and then deleted
when the procedure exits?  This is a LOCAL variable.  You need global storage.

>    case CWPM_CREATE:
>      hwndControl = WinCreateWindow(hwnd, WC_BUTTON, "Beep on WM_PAINT",
>                            WS_VISIBLE | BS_AUTOCHECKBOX,
>                            cx - 100, cy - 10, 200, 20, hwnd,
>                            HWND_TOP, ID_BUTTON, NULL, NULL);
>    case WM_PAINT:
>      if (SHORT1FROMMR(WinSendMsg(hwndControl, BM_QUERYCHECK, NULL, NULL))) WinAlarm(HWND_DESKTOP, WA_NOTE);
>      return(WinDefWindowProc(hwnd, msg, mp1, mp2));
>      break;

When this statement is executed, hwndControl is undefined. Either define your
variable outside the context of the window procedure, or use the window word
to store the handle.

Here's another suggestion that is better than the other two. If you change
your WM_PAINT processing to: 

if (SHORT1FROMMR(WinSendMsg( WinWindowFromID(hwnd, ID_BUTTON),
                             BM_QUERYCHECK,
                             NULL,
                             NULL)
                 )
   )
   WinAlarm(HWND_DESKTOP, WA_NOTE);

you won't need the variable. WinWindowFromID returns the window handle of
a window given the window's parent and the unique window id. This will only
work if all children of hwnd have unique id's. (or at least the window id
you are querying is unique.)


______________________________________________________________________________
     Michael Harris - harris@catt.ncsu.edu or harris@carvm3.vnet.ibm.com
 System Administrator, Computer & Technologies Theme Program, NC State Univ.
(My opinions are my own and do not represent those of NCSU or IBM Corporation)
From: martin@minster.york.ac.uk
Newsgroups: comp.os.os2.programmer
Subject: Re: Win NT Dev, Conf. Report'
Date: 24 Jul 92 22:58:24 GMT
Organization: Department of Computer Science, University of York, England

Tim smith writes:
> This should let them get kernel stability (which was what this was originally
> about).  Sure, there will be bugs in the first NT release, but I would expect
> them to be relatively minor, rather than things that can crash the kernel.
> 
> --Tim Smith

folks, I've been running NT since the middle off the week, and haven't had a
single kernel crash in that time. I wish I could say the same for OS/2 GA!

Let's face it, NT *already* has the kernel stability! It's the applications
that Microsoft will have to work on getting stable! (by which I mean all
the admin tools, etc)

Martin
INTERNET: martin@minster.york.ac.uk
JANET:  martin@uk.ac.york.minster
surface:
        Dr. Martin C. Atkins
        Dept. of Computer Science
        University of York
        Heslington
        York YO1 5DD
        ENGLAND
Newsgroups: comp.os.os2.programmer
From: feustel@netcom.com (David Feustel)
Subject: Re: Run ZTC 32-Bit DosX Code under OS/2!!!
Date: Sat, 25 Jul 92 14:51:05 GMT
Organization: DAFCO: OS/2 Software Support & Consulting

I discovered late last night that increasing the DPMI memory limit in
the dos settings got rid of what I thought was a VM error.
-- 
Dave Feustel N9MYI <feustel@netcom.com>
---
What's the different between a Salem Witch Hunter and a modern day
Drug Warrior? - 3 centuries.
Xref: sparky comp.os.os2.programmer:3686 comp.os.ms-windows.programmer.tools:531
From: kkluge@Materna.DE (Klaus Kluge)
Newsgroups: comp.os.os2.programmer,comp.os.ms-windows.programmer.tools
Subject: IBM Mirrors/2, porting from Windows to OS/2
Date: 21 Jul 92 11:54:48 GMT
Followup-To: comp.os.os2.programmer

We are planning to port a MS-WINDOWS application to OS/2,
and are thinking of using Micrografx Mirrors as the first
step. I've been told that Micrografx has licensed Mirrors
to IBM, and that IBM is releasing it as IBM Mirrors/2.

Unfortunately it seems that it isn't sold yet, at least
not in Germany. Has it been released somewhere else? When
will it be released?

The comp.os.os2.programmer FAQ lists Mirrors as a component
of IBM Workset/2, but this isn't on the current list of IBM
products neither. The other componentes of the Workset
(C Set/2, Workframe/2 and the Developer's Toolkit) also don't
include Mirrors.

I must confess, I am confused now.
_____
Klaus Kluge, Dr. Materna GmbH, Vosskuhle 37, DW-4600 Dortmund 1, Germany
INET: kkluge@Materna.DE   TEL.: +49-231-5599-301   FAX: +49-231-5599-100
Newsgroups: comp.os.os2.programmer
From: stewart@wimsey.bc.ca (Jim Stewart)
Subject: Re: Can someone at IBM please explain why developers should develop for OS/2?
Organization: Wimsey 
Date: Thu, 30 Jul 1992 07:04:55 GMT

IBM:

This is another voice from the wilderness. You could reduce the noise on
the net fairly inexpensivly...

Put the online API references and selected tools (dialog editor and help
compiler) on the net.  Think of it as an investment. 

js who_will_use_gcc_anyway
From: bking@ersys.edmonton.ab.ca (Barry King)
Newsgroups: comp.os.os2.programmer
Subject: Re: WorkFrame/2 debug kernel crashes
Keywords: os/2 programmer debug
Date: Thu, 23 Jul 92 00:46:25 MDT
Organization: Edmonton Remote Systems #3, Edmonton, AB, Canada

rpack@javelin.sim.es.com (Rick Pack) writes:

> I just installed the WorkFrame/2 development software on my system.  Everythi
> seems to work just fine, with one exception.  After installing the debug kern
> and re-booting, the system crashes after just a few seconds.  (I was worried
> I wouldn't be able to swap back to the normal kernel before it crashed.)
> 
> The crash completely locks up the mouse and ctl-alt-del doesn't work.  After
> removing the debug kernel, all is fine again.
> 
> My system is a 33 mhz 486 with 16 megs of ram and an ESDI drive.
> 
 
I too recently installed the debug kernel.  I also installed the PM debug 
DLLs at the same time.  I did not, however, experience the crashes that 
you have.  I also have a 486/33 with 16 Mb.  I do know that erratic 
behaviour can be expected if thePM debug DLLs are installed without the 
debug kernel.  Perhaps the converse is also true although I don't have a 
good explanation as to why that would be the case...
 

Barry King              bking@ersys.edmonton.ab.ca
Edmonton Remote Systems:  Celebrating 10 years of service to Northern Alberta
Newsgroups: comp.os.os2.programmer
From: toddc@cray.com (Todd Crowe)
Subject: Re: The expensive IBM doc set
Date: 30 Jul 92 08:49:58 CDT

dlb5404@tamsun.tamu.edu (Daryl Biberdorf) writes:
>Something that I haven't seen mentioned in this discussion (or I may have
>missed it) is that you don't have to buy all 17 volumes.  Each volume
>has its own IBM publication number, so you can order them separately
>(or so a Team OS/2 member tells me).

>Now, would someone who was rich enough to pay the $300 volunteer to
>post the title and publication number (and maybe even a brief
>description) of each volume in the set?  Chances are, most of us will
>only need a handful of volumes to get our job done.

If you have a copy of the Developer's Toolkit, you can find the numbers
in the back of the "Getting Started" manual.

- Todd Crowe
Newsgroups: comp.os.os2.programmer
From: tcf9033@venus.tamu.edu (FREY, TONY C)
Subject: Workframe/2 doesn't do HPFS?
News-Software: VAX/VMS VNEWS 1.41    
Organization: Texas A&M University, Academic Computing Services
Date: Thu, 30 Jul 1992 19:24:00 GMT

 does Workframe/2 not support HPFS? The reason I ask is I was working on a
project called PARTITION, which had all the extensions for the various files
(.c,.mak,.dep, etc) but Link386 and Nmake both bailed when they hit the
filename saying that they had to convert it to 8.3 format. What gives? The
IBM OS/2 compiler can't use the benefit of long filenames????  Do I just
have something set up wrong???

Tony Frey
TCF9033@venus.tamu.edu
Computer Engineering Undergrad 
Newsgroups: comp.os.os2.programmer
From: toddc@cray.com (Todd Crowe)
Subject: Re: Hints: Hooks
Date: 30 Jul 92 12:41:43 CDT

rofische@iiic.ethz.ch (Roman Fischer) writes:
>after trying around with hooks for nearly a week now, I found the following
>points that seem to be important:

>2. The Example in the Microsoft Programers Reference for OS/2 1.3 Vol. 1 is
>   wrong. The hook-procedure has 3 arguments, as defined before the example.

Actually the number and type of arguments are dependant on the hook.
Take a look at the comments/examples in the pmwin.h that comes with the
IBM Toolkit.

>I'm currently writting a hook for the system input queue (HK_INPUT), and I'll
>post it here as soon as possible (one or two days...).

Please do.

>bye                 Roman

Todd Crowe