freetds AT lists.ibiblio.org
Subject: FreeTDS Development Group
List archive
Re: [freetds] freebcp text column width limit is 4090
- From: "James K. Lowden" <jklowden AT schemamania.org>
- To: FreeTDS Development Group <freetds AT lists.ibiblio.org>
- Subject: Re: [freetds] freebcp text column width limit is 4090
- Date: Tue, 11 Mar 2003 00:24:46 -0500
On Mon, 10 Mar 2003 14:08:10 -0500, "Lowden, James K"
<LowdenJK AT bernstein.com> wrote:
>
> I have a table with a text column. Attempting to load it, freebcp
> segfaults if the column's data are more than 4090 bytes.
_bcp_get_term_data is passed a buffer into which it places a column's
worth of data. It is not told how big the buffer is, and the caller
allocates only 4096 bytes, statically.
I changed the signature to accept an array of pointers, the first of which
is allocated by the caller. If _bcp_get_term_data requires more room, it
allocates subsequent members of the array in 1 MB chunks. The array has
1000 pointers; if it's exhausted, we need more address space. The caller
knows from the returned size how many buffers (if any) were allocated.
I haven't committed yet because it doesn't work yet. I just wanted you to
know I've isolated the problem and solved it, in principle.
--jkl
-
[freetds] freebcp text column width limit is 4090,
Lowden, James K, 03/10/2003
- Re: [freetds] freebcp text column width limit is 4090, James K. Lowden, 03/11/2003
- <Possible follow-up(s)>
- RE: [freetds] freebcp text column width limit is 4090, Thompson, Bill D (London), 03/11/2003
- RE: [freetds] freebcp text column width limit is 4090, Lowden, James K, 03/11/2003
Archive powered by MHonArc 2.6.24.