× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



>I am trying to read an IFS file using the C function "read". I am
getting >the error message MCH1210. (Receiver value too small to hold
result).

>snip

>0230.00 D BufferI         S          10240A   Inz(*Blank)         
>0231.00 D  BufferI@       S               *   Inz(%Addr(BufferI)) 
>0232.00 D NBytes          S             10U 0                     
>0233.00 D NBytesSet       S             10U 0 Inz(10240)          
>0234.00 D RecIn           S          10240A                       
>0235.00 D CLRFPos         S             10I 0 Inz(0)              
>0236.00 D CLRF            S              2A   Inz(x'0d25')        

Just a small point but....

the read function returns the number of bytes read (defined as 10i0).
If however an error occurs, the function will return -1.
Not too sure that a 10u0 will suffice.

Suggest you change NBytes to 10i0 to match the procedure.

This may not be your problem tho'....

HTH

Mike

--




As an Amazon Associate we earn from qualifying purchases.

This thread ...


Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

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.