remove compile warning under some gcc versions
parent
ed65725833
commit
f4020e7622
1
make.sh
1
make.sh
|
|
@ -250,6 +250,7 @@ sed_replace()
|
|||
|
||||
cd src
|
||||
cp Makefile.in Makefile
|
||||
sed_replace "s#\\\$(CC)#gcc#g" Makefile
|
||||
sed_replace "s#\\\$(CFLAGS)#$CFLAGS#g" Makefile
|
||||
sed_replace "s#\\\$(INCS)#$INCS#g" Makefile
|
||||
sed_replace "s#\\\$(LIBS)#$LIBS#g" Makefile
|
||||
|
|
|
|||
|
|
@ -57,7 +57,7 @@ int write_to_pid_file(const char *pidFilename)
|
|||
int delete_pid_file(const char *pidFilename)
|
||||
{
|
||||
int result;
|
||||
pid_t pid;
|
||||
pid_t pid = 0;
|
||||
|
||||
if ((result=get_pid_from_file(pidFilename, &pid)) != 0) {
|
||||
return result;
|
||||
|
|
@ -115,7 +115,7 @@ static int do_stop(const char *pidFilename, const bool bShowError, pid_t *pid)
|
|||
int process_stop_ex(const char *pidFilename, const bool bShowError)
|
||||
{
|
||||
#define MAX_WAIT_COUNT 300
|
||||
pid_t pid;
|
||||
pid_t pid = 0;
|
||||
int result;
|
||||
int sig;
|
||||
int i;
|
||||
|
|
@ -192,7 +192,7 @@ static const char *get_exename_by_pid(const pid_t pid, char *buff,
|
|||
|
||||
int process_start(const char* pidFilename)
|
||||
{
|
||||
pid_t pid;
|
||||
pid_t pid = 0;
|
||||
int result;
|
||||
|
||||
if ((result=get_pid_from_file(pidFilename, &pid)) != 0) {
|
||||
|
|
|
|||
|
|
@ -3983,7 +3983,7 @@ int fc_get_last_line(const char *filename, char *buff,
|
|||
int fc_get_last_lines(const char *filename, char *buff,
|
||||
const int buff_size, string_t *lines, int *count)
|
||||
{
|
||||
int64_t file_size;
|
||||
int64_t file_size = 0;
|
||||
int64_t offset;
|
||||
int64_t read_bytes;
|
||||
int remain_len;
|
||||
|
|
|
|||
Loading…
Reference in New Issue