Petr Písař [Sun, 20 Aug 2017 20:15:25 +0000 (22:15 +0200)]
Fix parsing empty QUERY_STRING
If an CGI script is requested vith GET method without any query parameters,
the QUERY_STRING environment value will be an empty string. The old code
reported an error in this case by returning NULL from cgiInit(). This
patch fixes it.
This patch also fixes a memory leak in cgiReadVariables(). The query
string duplicated into line variable was never deallocated. This is
fixed now. Actually in any error raised from cgiReadVariables() forgets
to deallocted line and other variables but since it's an error state for
short-time living CGI script I did not bother fixing them.
Michel Stam [Sun, 4 May 2014 20:28:50 +0000 (22:28 +0200)]
Fix memory leaks found by valgrind
Joey Schulze [Mon, 5 May 2014 11:54:55 +0000 (13:54 +0200)]
Memset improvement inspired by Michael Rayment <mtr@mun.ca>
Joey Schulze [Wed, 1 Jul 2009 16:05:14 +0000 (16:05 +0000)]
Terminate a freshly allocated string as well.
Joey Schulze [Wed, 1 Jul 2009 16:03:02 +0000 (16:03 +0000)]
Correct header creation. Ensure the new string contains enough NUL bytes.
Thanks to Tyler McHenry
Joey Schulze [Tue, 30 Jun 2009 20:57:20 +0000 (20:57 +0000)]
Remove spurious extern, thanks to Tyler McHenry
Joey Schulze [Sun, 8 Feb 2009 17:12:53 +0000 (17:12 +0000)]
Finalise changelog
Joey Schulze [Sun, 8 Feb 2009 17:10:39 +0000 (17:10 +0000)]
Preparation for new release 0.7
Joey Schulze [Sun, 8 Feb 2009 16:55:41 +0000 (16:55 +0000)]
ABI version needs to be higher than 0 for Debian packaging
Joey Schulze [Sun, 8 Feb 2009 14:13:57 +0000 (14:13 +0000)]
Need to copy files before distribution, symlinks are bad
Joey Schulze [Sun, 8 Feb 2009 14:03:50 +0000 (14:03 +0000)]
No config directory anymore
Joey Schulze [Sat, 7 Feb 2009 13:31:43 +0000 (13:31 +0000)]
Add SONAME information
Joey Schulze [Mon, 12 Jan 2009 08:13:21 +0000 (08:13 +0000)]
Untypo
Joey Schulze [Sun, 11 Jan 2009 21:59:16 +0000 (21:59 +0000)]
Patch by W. Michael Petullo to use autotools for strncpy()
Joey Schulze [Sun, 11 Jan 2009 21:12:58 +0000 (21:12 +0000)]
Switch to autotools: readme renamed into README
Joey Schulze [Sun, 11 Jan 2009 21:08:42 +0000 (21:08 +0000)]
Switch to autotools: CREDITS renamed into AUTHORS
Joey Schulze [Sun, 11 Jan 2009 21:07:12 +0000 (21:07 +0000)]
Switch to autotools: CHANGES renamed into ChangeLog
Joey Schulze [Sun, 11 Jan 2009 20:49:41 +0000 (20:49 +0000)]
Add a headline
Joey Schulze [Sun, 11 Jan 2009 20:27:31 +0000 (20:27 +0000)]
Convert to autotools
Joey Schulze [Sun, 11 Jan 2009 20:09:37 +0000 (20:09 +0000)]
Prepare for autotools
Joey Schulze [Sun, 11 Jan 2009 20:00:14 +0000 (20:00 +0000)]
Prepare for autotools
Joey Schulze [Sun, 16 Nov 2008 19:25:13 +0000 (19:25 +0000)]
Add Phil Brooke to list of contributors
Joey Schulze [Sun, 16 Nov 2008 19:23:29 +0000 (19:23 +0000)]
Patch by Phil Brooke <pjb@scm.tees.ac.uk> to allow cookies without
regular CGI POST/GET variables
Joey Schulze [Sun, 6 Apr 2008 12:45:54 +0000 (12:45 +0000)]
Removed reference to www.infodrom.north.de
Joey Schulze [Sun, 6 Apr 2008 09:54:00 +0000 (09:54 +0000)]
Add CVS information
Joey Schulze [Sun, 6 Apr 2008 09:51:29 +0000 (09:51 +0000)]
Document changes
Joey Schulze [Sun, 6 Apr 2008 09:43:53 +0000 (09:43 +0000)]
Add the GPLv2 itself
Joey Schulze [Sun, 6 Apr 2008 09:43:43 +0000 (09:43 +0000)]
Update to the new FSF address
Joey Schulze [Sun, 6 Apr 2008 09:33:05 +0000 (09:33 +0000)]
Updates
Joey Schulze [Sun, 6 Apr 2008 09:16:46 +0000 (09:16 +0000)]
Adjust the date to today
Joey Schulze [Fri, 8 Feb 2008 10:36:20 +0000 (10:36 +0000)]
Beautification
Joey Schulze [Mon, 21 Jan 2008 20:39:41 +0000 (20:39 +0000)]
Need to decode variable names as well, and consistently the content
Joey Schulze [Mon, 21 Jan 2008 19:52:47 +0000 (19:52 +0000)]
Untypo
Joey Schulze [Mon, 21 Jan 2008 10:52:36 +0000 (10:52 +0000)]
Improvement by Neil Spring: Declare some arguments const
Joey Schulze [Mon, 21 Jan 2008 10:41:49 +0000 (10:41 +0000)]
Added support for inclusion into C++
Joey Schulze [Sun, 20 Jan 2008 19:04:03 +0000 (19:04 +0000)]
Support for uploaded files, beautification of the output, improved
HTML, more examples
Joey Schulze [Mon, 17 Dec 2007 16:00:51 +0000 (16:00 +0000)]
Small improvements
Joey Schulze [Sun, 16 Dec 2007 16:40:43 +0000 (16:40 +0000)]
-lcgi not required in local directory
Joey Schulze [Sun, 16 Dec 2007 16:40:23 +0000 (16:40 +0000)]
Updates
Joey Schulze [Sun, 16 Dec 2007 16:39:01 +0000 (16:39 +0000)]
Refer to freeing memory
Joey Schulze [Fri, 14 Dec 2007 15:58:01 +0000 (15:58 +0000)]
Document cgiFree
Joey Schulze [Fri, 14 Dec 2007 15:39:50 +0000 (15:39 +0000)]
Remove temporary files at the end
Joey Schulze [Fri, 14 Dec 2007 15:09:09 +0000 (15:09 +0000)]
Bugfix
Joey Schulze [Fri, 14 Dec 2007 15:01:55 +0000 (15:01 +0000)]
Added documentation
Joey Schulze [Thu, 13 Dec 2007 18:44:33 +0000 (18:44 +0000)]
Support functions for transmitted files
Joey Schulze [Fri, 7 Dec 2007 16:30:40 +0000 (16:30 +0000)]
Hint freeing memory
Joey Schulze [Fri, 7 Dec 2007 15:08:51 +0000 (15:08 +0000)]
free CGI data structures
Joey Schulze [Fri, 7 Dec 2007 14:49:52 +0000 (14:49 +0000)]
text update
Joey Schulze [Thu, 6 Dec 2007 18:35:47 +0000 (18:35 +0000)]
memory correction
Joey Schulze [Thu, 6 Dec 2007 18:32:45 +0000 (18:32 +0000)]
Use cgiFreeList to free the list
Joey Schulze [Thu, 6 Dec 2007 17:11:17 +0000 (17:11 +0000)]
indention
Joey Schulze [Wed, 5 Dec 2007 20:10:22 +0000 (20:10 +0000)]
Added new reference
Joey Schulze [Wed, 5 Dec 2007 19:52:12 +0000 (19:52 +0000)]
Add cgiGetFiles to list functions
Joey Schulze [Wed, 5 Dec 2007 19:48:34 +0000 (19:48 +0000)]
Document cgiGetFiles
Joey Schulze [Wed, 5 Dec 2007 19:44:25 +0000 (19:44 +0000)]
Untypo
Joey Schulze [Sun, 2 Dec 2007 22:27:01 +0000 (22:27 +0000)]
Improved output
Joey Schulze [Sun, 2 Dec 2007 22:25:15 +0000 (22:25 +0000)]
Added support for uploaded files to the input parser
Joey Schulze [Sun, 2 Dec 2007 22:23:47 +0000 (22:23 +0000)]
Free all allocated space
Joey Schulze [Sun, 2 Dec 2007 22:22:01 +0000 (22:22 +0000)]
Don't abuse variables
Joey Schulze [Sun, 2 Dec 2007 22:19:42 +0000 (22:19 +0000)]
Be less verbose
Joey Schulze [Sun, 2 Dec 2007 22:19:22 +0000 (22:19 +0000)]
free type if set
Joey Schulze [Sun, 2 Dec 2007 22:13:58 +0000 (22:13 +0000)]
Corrected pointer arithmetic
Joey Schulze [Sun, 2 Dec 2007 22:05:44 +0000 (22:05 +0000)]
Parse function need to return the s_cgi structure in preparation of
file upload support
Joey Schulze [Sun, 2 Dec 2007 21:48:26 +0000 (21:48 +0000)]
data structure for uploaded files
Joey Schulze [Thu, 29 Nov 2007 15:13:02 +0000 (15:13 +0000)]
Adjust verbosity
Joey Schulze [Thu, 29 Nov 2007 14:16:58 +0000 (14:16 +0000)]
Document basic support for multipart/form-data
Joey Schulze [Thu, 29 Nov 2007 13:58:25 +0000 (13:58 +0000)]
Added basic support for multipart/form-data
Joey Schulze [Thu, 29 Nov 2007 13:54:27 +0000 (13:54 +0000)]
Added internal routine to read input
Joey Schulze [Wed, 28 Nov 2007 14:06:34 +0000 (14:06 +0000)]
Append newline after each log line on stderr
Joey Schulze [Wed, 28 Nov 2007 14:05:01 +0000 (14:05 +0000)]
A newline will be appended on demand when debug output is emitted
Joey Schulze [Wed, 28 Nov 2007 13:59:22 +0000 (13:59 +0000)]
Don't trust Content-Length too much
Joey Schulze [Tue, 27 Nov 2007 18:45:29 +0000 (18:45 +0000)]
Include syslog header
Joey Schulze [Tue, 27 Nov 2007 18:16:49 +0000 (18:16 +0000)]
Open the channel to syslog if needed
Joey Schulze [Tue, 27 Nov 2007 18:02:27 +0000 (18:02 +0000)]
Documentation update
Joey Schulze [Tue, 27 Nov 2007 18:01:27 +0000 (18:01 +0000)]
Restructurisation: moved debug code into general routine, and into aux file
Joey Schulze [Sun, 25 Nov 2007 21:19:50 +0000 (21:19 +0000)]
Demonstrate GET variables
Joey Schulze [Sun, 25 Nov 2007 21:12:25 +0000 (21:12 +0000)]
Updated URLs
Joey Schulze [Sun, 25 Nov 2007 21:04:48 +0000 (21:04 +0000)]
Removed included changelog
Joey Schulze [Sun, 25 Nov 2007 19:16:11 +0000 (19:16 +0000)]
Take care of null termination
Joey Schulze [Sun, 25 Nov 2007 19:09:56 +0000 (19:09 +0000)]
Simplify and unify code
Joey Schulze [Sun, 25 Nov 2007 19:09:24 +0000 (19:09 +0000)]
Use \r\n in headers
Joey Schulze [Sun, 25 Nov 2007 18:55:03 +0000 (18:55 +0000)]
Use \r\n in headers
Joey Schulze [Sun, 25 Nov 2007 18:34:18 +0000 (18:34 +0000)]
<malloc.h> is obsolete, use <stdlib.h>
Joey Schulze [Sun, 25 Nov 2007 18:32:13 +0000 (18:32 +0000)]
Spelling corrections by Stephen Uitti
Joey Schulze [Sun, 25 Nov 2007 18:03:36 +0000 (18:03 +0000)]
Properly return NULL when the variable is empty
Joey Schulze [Sun, 25 Nov 2007 16:41:17 +0000 (16:41 +0000)]
New contributor
Joey Schulze [Sun, 25 Nov 2007 16:17:54 +0000 (16:17 +0000)]
Patch by Laszlo Zavaleta <wry@kopu.org> to accept ';' as delimiter
Joey Schulze [Sun, 25 Nov 2007 16:04:51 +0000 (16:04 +0000)]
Escape potentially characters
Joey Schulze [Sun, 25 Nov 2007 16:04:28 +0000 (16:04 +0000)]
Added auxilliary routines
Joey Schulze [Sun, 25 Nov 2007 15:58:51 +0000 (15:58 +0000)]
Documentation
Joey Schulze [Sun, 25 Nov 2007 15:46:53 +0000 (15:46 +0000)]
Auxilliary routines
Joey Schulze [Sun, 25 Nov 2007 15:39:53 +0000 (15:39 +0000)]
Adjust the mail address
Joey Schulze [Tue, 3 May 2005 03:38:50 +0000 (03:38 +0000)]
Added missing include file for strcmp() and strlen()
Joey Schulze [Fri, 14 Dec 2001 18:09:52 +0000 (18:09 +0000)]
* Darn, f*cking DEB_BUILD_OPTIONS support broke the build system. Found
a way to workaround this by cheating but it seems to work this
time.
Joey Schulze [Thu, 22 Nov 2001 08:25:10 +0000 (08:25 +0000)]
Added convenience code to support $DEB_BUILD_OPTIONS
Joey Schulze [Tue, 20 Nov 2001 21:14:50 +0000 (21:14 +0000)]
Updated addresses
Joey Schulze [Mon, 24 Apr 2000 16:07:22 +0000 (16:07 +0000)]
typo
Joey Schulze [Sat, 6 Nov 1999 12:09:37 +0000 (12:09 +0000)]
removed misplaced quotes
Joey Schulze [Fri, 20 Aug 1999 21:32:32 +0000 (21:32 +0000)]
. Added homepage to readme
. Adjusted copyright file
Joey Schulze [Fri, 20 Aug 1999 21:29:37 +0000 (21:29 +0000)]
Set final dates