-Wall cleanups

This commit is contained in:
Ron Pedde 2006-03-25 11:15:53 +00:00
parent 4d1555ec2b
commit 51a3a6279c
5 changed files with 10 additions and 4 deletions

View File

@ -640,6 +640,7 @@ char *conf_alloc_string (char *section, char *key, char *dflt) {
int size = -1;
char *out;
/* FIXME: races */
conf_get_string(section, key, dflt, NULL, &size);
out = (char *)malloc(size * sizeof(char));

View File

@ -320,7 +320,7 @@ void config_handler(WS_CONNINFO *pwsc) {
char web_root[PATH_MAX];
int file_fd;
struct stat sb;
char *pw, *web_root;
char *pw;
int size;
size = sizeof(web_root);

View File

@ -29,7 +29,12 @@
#include <stdio.h>
#include <stdarg.h>
#include <stdlib.h>
#include <string.h>
#ifdef HAVE_STRING_H
# include <string.h>
#endif
#ifdef HAVE_STRINGS_H
# include <strings.h>
#endif
#include "db-generic.h"
#include "err.h"

View File

@ -192,7 +192,7 @@ void daap_handler(WS_CONNINFO *pwsc) {
*/
pqi->index_type=indexTypeNone;
l = h = 0;
index=ws_getvar(pwsc,"index");
if(index) {
DPRINTF(E_DBG,L_DAAP,"Indexed query: %s\n",index);

View File

@ -451,7 +451,7 @@ static struct RB_ENTRY(node) *
RB_ENTRY(_lookup)(int mode, const RB_ENTRY(data_t) *key, struct RB_ENTRY(tree) *rbinfo)
{
struct RB_ENTRY(node) *x,*y;
int cmp;
int cmp=0;;
int found=0;
y=RBNULL; /* points to the parent of x */