8e5abd345e
Temporary files used to accept file uploads were not closed properly. This resulted in a file descriptor leak, which was unlikely to be serious because of the short lifespan of CGI programs and the fact that very few forms upload many files at once. However, on the Windows platform and possibly some others, file locking semantics prevented file uploads from working at all with these files not properly closed. Fixed in 2.05. Changes 2.04: Documentation fixes: the cgiHtmlEscape, cgiHtmlEscapeData, cgiValueEscape, and cgiValueEscapeData routines were named incorrectly in the manual. No code changes in version 2.04. Changes 2.03: Support for setting cookies has been reimplemented. The new code closely follows the actual practice of web sites that successfully use cookies, rather than attempting to implement the specification. The new code can successfully set more than one cookie at a time in typical web browsers.
34 lines
1.5 KiB
Text
34 lines
1.5 KiB
Text
$NetBSD: patch-ae,v 1.2 2006/01/06 22:46:51 adam Exp $
|
|
|
|
--- cgic.html.orig 2004-11-15 17:59:19.000000000 +0100
|
|
+++ cgic.html
|
|
@@ -378,6 +378,29 @@ cgic.c to your project?</strong>
|
|
If none of the above proves effective, please see the
|
|
section regarding <a href="#support">support</a>.
|
|
<h3><a name="howto">How to write a cgic application</a></h3>
|
|
+
|
|
+<strong><em>Important Note for NetBSD packages users from the package maintainer: </em>
|
|
+<p>
|
|
+This section does not work for users of cgic who have it installed via
|
|
+a NetBSD package. While mostly true, there are several very important
|
|
+differences which were created during the port to the NetBSD pkgsrc
|
|
+environment:
|
|
+
|
|
+<ul>
|
|
+<li> Linking is now done against libcgic instead of cgic.c itself. This
|
|
+ is done by adding a "-lcgic" and other command line options as needed
|
|
+ when linking.
|
|
+<li> The application must now provide its own main() function, which calls the
|
|
+ cgiInit() function before any of the other functions are called. This
|
|
+ function returns 0 upon success, and -1 upon failure. It also registers
|
|
+ a function, cgiFreeResources(), via atexit() to be called at exit time.
|
|
+</ul>
|
|
+
|
|
+While this removes the ability to compile cgic with DEBUG defined, it
|
|
+aligns the cgic library with the model followed by other libraries.
|
|
+</strong>
|
|
+<p>
|
|
+
|
|
<em>Note: </em> All cgic applications must be linked to the cgic.c module
|
|
itself. How to do this depends on your operating system; under Unix,
|
|
just use the provided Makefile as an example.
|