Go Back   System iNetwork Forums > Development > RPG

Reply
 
Thread Tools Display Modes
  #1  
Old 02-08-2010, 07:25 PM
Vlad Vlad is offline
Member
 
Join Date: Feb 2006
Location: Wellington, NZ
Posts: 184
How to override stderr in RPG ILE pgm?

Hi,
I have an issue with the C error messages appearing on the screen for a short time when calling a C function from the RPG pgm.
I'm analysing the error code in my RPG PGM so everything is under control.
The only question is how to prevent the error message text from being displayed on the screen ? I assume that the C functions just send the messages to the stderr output so it needs to be redirected somehow. May be there is another way. Basically I just don't want the messages to be displayed.

Example of the message I have:"AXIS EXCEPTION: (
66
)
AxisParseException: Error when getting the byte stream from the transport.
HTTPTransportException: Input streaming error while reading from channel.
Error is 3426 - A connection with a remote socket was reset by that socket. "
Thank you.
Reply With Quote
  #2  
Old 02-08-2010, 11:05 PM
Scott Klement's Avatar
Scott Klement Scott Klement is online now
 
Join Date: Jul 2005
Location: Milwaukee, WI, USA
Posts: 10,596
Code:
OVRDBF FILE(STDERR) TOFILE(QTEMP/SOMETHING)
Then delete QTEMP/SOMETHING when it's done.
Reply With Quote
  #3  
Old 02-09-2010, 11:54 AM
Vlad Vlad is offline
Member
 
Join Date: Feb 2006
Location: Wellington, NZ
Posts: 184
Scott,
it is possible to do this by using C API functions rather then OVRDBF?
May be by overriding the _C_IFS_stderr with something?
Reply With Quote
  #4  
Old 02-09-2010, 12:08 PM
Scott Klement's Avatar
Scott Klement Scott Klement is online now
 
Join Date: Jul 2005
Location: Milwaukee, WI, USA
Posts: 10,596
Hmm... not that I'm aware of?
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -6. The time now is 04:47 AM.