Subject: | |
From: | |
Reply To: | |
Date: | Wed, 17 Feb 1999 09:40:14 -0800 |
Content-Type: | text/plain |
Parts/Attachments: |
|
|
Ted writes:
> Things were going smoothly. I HPFOpened the file, did the FFILEINFO call and
> got the name into a character array. The rename worked beautifully. I
> appended a semi-colon to the POSIX name in the character array (as a
> terminating character--see HPFOPEN documentation) and called HPFOPEN. A bunch
> of debugging down the road, I discover that
For item#2 (file name), you need a special character at the START and at
the END ... not just at the end (and, btw, a semicolon isn't a good choice even
for FOPEN...I recommend blank or null ... you're probably too young :) to
remember the chaos caused by some HP programmer saying to himself/herself
"I'll use a colon").
I.e, to open /foo/fum/fie specify something like -/foo/fum/fie-
Yes, it's dumb...really dumb...whoever designed that aspect of HPFOPEN
should have simply said "terminate with a null" or something equally simple.
And, no, I don't think filenames should be allowed to have embedded blanks :)
> The PASCAL XL STRING OPTION (item# 51) is not valid, or a bounds violation
> occurred on this option. (FILE OPEN ERROR -455)
A common problem...using item 51 is harder than you think because of
a poor choice in the implementation of item 51. (I.e., the designer
compensated for a quirk of Pascal's procedure calling convention, rather than
documenting how to defeat Pascal ... but with the result that it's hard
to use by all non-Pascal callers, and some Pascal callers.)
<plug>
The answer to *that* problem is in the CSEQ output ... and I'm not
posting it this time :) Hint: cseq +hpfopen look at item 51
</plug>
--
Stan Sieler [log in to unmask]
http://www.allegro.com/sieler.html
|
|
|