|
Hello,file if that makes a difference...) and then I send it to a PC over a
I have an application that reads an image file off of the IFS (it's a TIFF
socket.the Unix-type API Send to send the file across the socket.
I'm using the _C_IFS_OPEN and _C_IFS_GETS to read the file and I'm using
getting corrupted. That is, the first few lines of the image data are fine,
The problem I'm having is that somewhere along the way, my image file is
and in fact, you can even make out a little bit of what the image is ifyou look at it in Windows. But somewhere between the last point where I have
good data and the end of the file (or possibly including the end of thefile too), my image data gets altered.
see that the data is MOSTLY correct. however, there are places where the
If I look at the file in Notepad or Wordpad or even in a DOS prompt, I can
data is obviously different. And since it's in hex (or whatever...) it'simpossible for me to look at it and say, "Oh, there's a line feed or
return there where there shouldn't be."and the _OPEN and _GETS APIs (as shown above)), do you think my chances of
So, what I'm wondering is... If I used the Send_File API (instead of SEND
avoiding trashed data would improve? I guess I could just try it and seebut I was hoping someone might have used Send_File before and had some
experience with it.process:
There are 3 distinct points where the data could be getting hosed in this
worked flawlessly for years. On the other hand, I don't know if I've ever
1. When I read the data using the _C_IFS_GETS API.
2. When the data is sent across the socket from my RPGLE program.
3. When the data is received at the socket server.
The last one does not seem as likely simply because that process has
an image file like this before to it. This might be a first for me as it'sbeen awhile since I messed with any of this, I don't really remember.
file from the IFS or it's in the send across the socket.
It seems more likely to me that the problem is either in the Read or the
Thoughts, opinions suggestions and anything else is welcome.
thanks,
Shannon O'Donnell
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.