old testlo example code

From: Josh Kupershmidt <schmiddy(at)gmail(dot)com>
To: pgsql-docs <pgsql-docs(at)postgresql(dot)org>
Subject: old testlo example code
Date: 2013-01-05 02:27:14
Message-ID: CAK3UJRFL8OD9Me-vPaE=ELPZ5-hFmk_Psa-cF00YfQJ7GNua-w@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-docs

This documentation page:
http://www.postgresql.org/docs/current/static/lo-examplesect.html

contains a hardcoded copy of ./src/test/examples/testlo.c, and it
seems like this version hasn't been updated along with its source. The
version from the docs no longer compiles for me, at least not when I
drop it into the place of the current ./src/test/examples/testlo.c.
That's easy enough to fix, though I have a historical question about
this code.

Building the unmodified code in ./src/test/examples, I see:

testlo.c:35: warning: ‘importFile’ defined but not used
testlo.c:151: warning: ‘exportFile’ defined but not used
...
testlo64.c:35: warning: ‘importFile’ defined but not used
testlo64.c:173: warning: ‘exportFile’ defined but not used

since the calls to those functions are commented out in favor of
lo_import() and lo_export(). I'm wondering if there is some reason to
leave those importFile() and exportFile() definitions in this example
code if they're not used? The code has apparently been like this (at
least for testlo.c, and I guess testlo64.c just copy-pasted from its
older sibling) since the first commit, d31084e9.

Josh

Responses

Browse pgsql-docs by date

  From Date Subject
Next Message Magnus Hagander 2013-01-05 14:14:34 Re: old testlo example code
Previous Message Kevin Grittner 2013-01-04 20:11:52 Re: Unclear CHARACTER specification