<div dir="ltr">Rick, <div><br></div><div>Yes, my strings are going to be greater than 8192 characters, so this explains the error message. </div><div><br></div><div>Dave, </div><div><br></div><div>I used asciiwrite instead of write_table, and now I"m not getting this error. </div><div><br></div><div><br></div><div>Thanks so much for the help! </div><div><br></div><div>Micah</div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Fri, Sep 24, 2021 at 3:02 PM Dave Allured - NOAA Affiliate <<a href="mailto:dave.allured@noaa.gov">dave.allured@noaa.gov</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div>Please note that I suggested asciiwrite, not write_table.  Asciiwrite is different internal code that may very well not be limited to an 8192-character line length.  I did not check the internal code.</div><div><br></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Fri, Sep 24, 2021 at 12:55 PM Rick Brownrigg via ncl-talk <<a href="mailto:ncl-talk@mailman.ucar.edu" target="_blank">ncl-talk@mailman.ucar.edu</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div>Hi Micah,</div><div><br></div><div>It looks like the text of the error message actually comes from the standard C library.  I can't relate that directly to the NCL code, but looking at the code underlying write_table(), I can see that there's a character buffer of len 8192 that gets allocated to hold a line's worth of output in the table. The code builds up a line by stepping through each element in the list passed to write_table, formatting the element and appending the text to the character buffer. I don't see where there's ever a point at which the buffer is reallocated should it become full.</div><div><br></div><div>Is it possible your table lines are > 8192 characters?  Not that this information does you much good -- at least you know the potential limit, and can use Dave's advice to work within that bound.</div><div><br></div><div>Rick<br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Fri, Sep 24, 2021 at 12:01 PM Micah Sklut <<a href="mailto:micahs2005@gmail.com" target="_blank">micahs2005@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">Hi Rick, <div><br></div><div>Yes, it is a copy/paste of the error. </div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Fri, Sep 24, 2021 at 12:18 PM Rick Brownrigg <<a href="mailto:brownrig@ucar.edu" target="_blank">brownrig@ucar.edu</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div>Hi,</div><div><br></div><div>I can't find anywhere in the source code where such an error message would arise. Is that a literal copy/paste of the error?</div><div><br></div><div>Rick</div><div><br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Fri, Sep 24, 2021 at 10:03 AM Micah Sklut via ncl-talk <<a href="mailto:ncl-talk@mailman.ucar.edu" target="_blank">ncl-talk@mailman.ucar.edu</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">Hi NCL Talk, <div><br></div><div>I'm using write_table to output a large amount of data to file. </div><div>Here's the output statement: </div><div><br></div>alist = [/latPoints,lonPoints,hsString,perString,dirString,winduString,windvString,phs1String,phs2String,phs3String,phs4String,phs5String,phswindString,pdir1String,pdir2String,pdir3String,pdir4String,pdir5String,pdirwindString,ptp1String,ptp2String,ptp3String,ptp4String,ptp5String,ptpwindString/]<br><br>write_table("outf_data.txt","w",alist,"%6.3f,%6.3f,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s");<div><br></div><div>I'm getting the following message:</div><div><br></div>*** buffer overflow detected ***: ncl terminated<br>Aborted<div><br></div><div>When I reduce the string lengths of the variables, then I don't get this error, so I"m guessing I"m running into an NCL string length maximum? </div><div><br></div><div>Any suggestions on how to get around this problem? </div><div><br></div><div>Thank you. <br><div><br><div>-- <br><div dir="ltr">Micah Sklut<br></div></div></div></div></div></blockquote></div></blockquote></div></blockquote></div></blockquote></div></div>
</blockquote></div><br clear="all"><div><br></div>-- <br><div dir="ltr" class="gmail_signature">Micah Sklut<br><br></div>