goto too_small;
_cupsMD5Init(&state);
- _cupsMD5Append(&state, data, datalen);
+ _cupsMD5Append(&state, data, (int)datalen);
_cupsMD5Finish(&state, hash);
return (16);
if (!strcmp(name, "uri"))
{
char uri[1024]; /* New printer URI */
- http_uri_status_t uri_status; /* URI status */
- if ((uri_status = httpSeparateURI(HTTP_URI_CODING_ALL, value, v->scheme, sizeof(v->scheme), v->username, sizeof(v->username), v->host, sizeof(v->host), &(v->port), v->resource, sizeof(v->resource))) < HTTP_URI_STATUS_OK)
+ if (httpSeparateURI(HTTP_URI_CODING_ALL, value, v->scheme, sizeof(v->scheme), v->username, sizeof(v->username), v->host, sizeof(v->host), &(v->port), v->resource, sizeof(v->resource)) < HTTP_URI_STATUS_OK)
return (0);
if (v->username[0])
ippDelete(response);
response = NULL;
- http->status = status = HTTP_STATUS_ERROR;
+ http->status = HTTP_STATUS_ERROR;
http->error = EINVAL;
}
}
if (!cupsDoAuthentication(http, "POST", resource))
httpReconnect2(http, 30000, NULL);
else
- http->status = status = HTTP_STATUS_CUPS_AUTHORIZATION_CANCELED;
+ http->status = HTTP_STATUS_CUPS_AUTHORIZATION_CANCELED;
}
#ifdef HAVE_SSL
for (y = 0; y < header.cupsHeight; y ++)
cupsRasterWritePixels(ras, line, header.cupsBytesPerLine);
+ free(line);
+
cupsRasterClose(ras);
close(fd);
{
cups_file_t *fp; /* File to print */
int job_id; /* Job ID */
- ipp_status_t status; /* Submission status */
const char *title; /* Title of job */
char buffer[32768]; /* File buffer */
ssize_t bytes; /* Bytes read/to write */
else
title = filename;
- if ((status = cupsCreateDestJob(http, dest, dinfo, &job_id, title, num_options, options)) > IPP_STATUS_OK_IGNORED_OR_SUBSTITUTED)
+ if (cupsCreateDestJob(http, dest, dinfo, &job_id, title, num_options, options) > IPP_STATUS_OK_IGNORED_OR_SUBSTITUTED)
{
printf("Unable to create job: %s\n", cupsLastErrorString());
cupsFileClose(fp);
cupsFileClose(fp);
- if ((status = cupsFinishDestDocument(http, dest, dinfo)) > IPP_STATUS_OK_IGNORED_OR_SUBSTITUTED)
+ if (cupsFinishDestDocument(http, dest, dinfo) > IPP_STATUS_OK_IGNORED_OR_SUBSTITUTED)
{
printf("Unable to send document: %s\n", cupsLastErrorString());
return;