× 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 would have gotten a pointer to a user space and pass that to the API.
That way you effectively have up to 16 Megabytes of storage available.



Bob Cozzi
Cozzi Consulting
www.rpgiv.com


-----Original Message-----
From: web400-bounces@xxxxxxxxxxxx [mailto:web400-bounces@xxxxxxxxxxxx] On
Behalf Of Hans Boldt
Sent: Wednesday, September 17, 2003 10:35 AM
To: web400@xxxxxxxxxxxx
Subject: [WEB400] Re: QtmhRdStin and QzhbCgiParse Limitation

Bartell, Aaron L. (TC) wrote:

> <Hans>
> I was surprised it works because of problem #1 above. I would expect 
> that you shouldn't be able to read 11M of data into a 32K variable, 
> unless you're overwriting the subsequent locations in memory. You 
> may be just very lucky that you're not overwriting something 
> important. I think you still need to dynamically allocate all the 
> storage you need and read into that.
> </Hans>
> 
> 
> Actually I was assuming that QtmhRdStin was doing proper allocation for
me.
> Notice what I am passing in as the second parm to qtmhRdStin:
> qtmhRdStin(output: contentLength: bytesRead: ErrorDs);
> 
> Variable 'contentLength' has a value of 11,000,000 in my 11MB scenario.
> 
> Here is the documentation for QtmhRdStin:
>
http://publib.boulder.ibm.com/iseries/v5r2/ic2924/index.htm?info/rzaie/rzaie
> api_qtmhrdstin.htm 
> 
> Given that information don't you think it should work?  
> 

What specifically about the documentation for "QtmhRdStin" would 
lead you to believe that it would allocate the storage for you? Note 
that you're passing in the receiving field by reference, and so the 
data should get written to that variable. You're telling the API by 
the value in the second parameter that the receiving field is big 
enough for that amount of data, and the API has no reason to suspect 
you of lying to it.

Cheers! Hans


_______________________________________________
This is the Web Enabling the AS400 / iSeries (WEB400) mailing list
To post a message email: WEB400@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/web400
or email: WEB400-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/web400.





As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

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.