X-Git-Url: http://the.earth.li/gitweb/?a=blobdiff_plain;f=getcgi.c;h=c6f60c89afd5d6ce977733d252c384fa84039586;hb=f063495a9a479e094216875001e3e006344eebcd;hp=203584149b1e38320b397916a7ea161aae7d6162;hpb=5e1b22d763640c4d7a09d07920403d8d491b4410;p=onak.git
diff --git a/getcgi.c b/getcgi.c
index 2035841..c6f60c8 100644
--- a/getcgi.c
+++ b/getcgi.c
@@ -16,8 +16,7 @@
* more details.
*
* You should have received a copy of the GNU General Public License along with
- * this program; if not, write to the Free Software Foundation, Inc., 51
- * Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * this program. If not, see .
*/
#include
@@ -200,14 +199,14 @@ char **getcgivars(int argc, char *argv[])
for(i=0; cgiinput[i]; i++) if (cgiinput[i]=='+') cgiinput[i] = ' ';
/* First, split on "&" to extract the name-value pairs into pairlist */
- pairlist=(char **) malloc(256*sizeof(char **));
+ pairlist= malloc(256*sizeof(char *));
paircount=0;
nvpair=strtok(cgiinput, "&");
while (nvpair) {
pairlist[paircount++]= strdup(nvpair) ;
if (!(paircount%256)) {
- pairlist=(char **) realloc(pairlist,
- (paircount+256)*sizeof(char **));
+ pairlist= realloc(pairlist,
+ (paircount+256)*sizeof(char *));
}
nvpair=strtok(NULL, "&") ;
}
@@ -216,7 +215,7 @@ char **getcgivars(int argc, char *argv[])
/* Then, from the list of pairs, extract the names and values */
- cgivars=(char **) malloc((paircount*2+1)*sizeof(char **));
+ cgivars= malloc((paircount*2+1)*sizeof(char *));
for (i=0; i