Synchronet now requires the libarchive development package (e.g. libarchive-dev on Debian-based Linux distros, libarchive.org for more info) to build successfully.

Commit 0cef0d39 authored by deuce's avatar deuce

Various minor issues found by Coverity.

parent 0f7565a1
......@@ -1560,13 +1560,13 @@ static void parse_extended_colour(struct esc_seq *seq, int *i, struct cterminal
uint32_t nc;
uint32_t *co;
if (seq == NULL || cterm == NULL || i == NULL)
return;
if (fg)
FREE_AND_NULL(cterm->fg_tc_str);
else
FREE_AND_NULL(cterm->bg_tc_str);
co = fg ? (&cterm->fg_color) : (&cterm->bg_color);
if (seq == NULL || cterm == NULL || i == NULL)
return;
if (*i>=seq->param_count)
return;
......@@ -3992,6 +3992,7 @@ CIOLIBEXPORT char* CIOLIBCALL cterm_write(struct cterminal * cterm, const void *
/* Movement */
case 13: /* "\r\n" and disabled reverse. */
cterm->c64reversemode = 0;
/* Fall-through */
case 141:
GOTOXY(1, WHEREY());
/* Fall-through */
......
......@@ -976,26 +976,26 @@ int edit_list(struct bbslist **list, struct bbslist *item,char *listpath,int isd
default:
iniSetEnum(&inifile,itemname,"ScreenMode",screen_modes_enum,item->screen_mode,&ini_style);
if(item->screen_mode == SCREEN_MODE_C64) {
strcpy(item->font,font_names[33]);
SAFECOPY(item->font,font_names[33]);
iniSetString(&inifile,itemname,"Font",item->font,&ini_style);
item->nostatus = 1;
iniSetBool(&inifile,itemname,"NoStatus",item->nostatus,&ini_style);
}
if(item->screen_mode == SCREEN_MODE_C128_40
|| item->screen_mode == SCREEN_MODE_C128_80) {
strcpy(item->font,font_names[35]);
SAFECOPY(item->font,font_names[35]);
iniSetString(&inifile,itemname,"Font",item->font,&ini_style);
item->nostatus = 1;
iniSetBool(&inifile,itemname,"NoStatus",item->nostatus,&ini_style);
}
if(item->screen_mode == SCREEN_MODE_ATARI) {
strcpy(item->font,font_names[36]);
SAFECOPY(item->font,font_names[36]);
iniSetString(&inifile,itemname,"Font",item->font,&ini_style);
item->nostatus = 1;
iniSetBool(&inifile,itemname,"NoStatus",item->nostatus,&ini_style);
}
if(item->screen_mode == SCREEN_MODE_ATARI_XEP80) {
strcpy(item->font,font_names[36]);
SAFECOPY(item->font,font_names[36]);
iniSetString(&inifile,itemname,"Font",item->font,&ini_style);
item->nostatus = 1;
iniSetBool(&inifile,itemname,"NoStatus",item->nostatus,&ini_style);
......@@ -1128,7 +1128,7 @@ int edit_list(struct bbslist **list, struct bbslist *item,char *listpath,int isd
break;
default:
if(i!=find_font_id(item->font)) {
strcpy(item->font,font_names[i]);
SAFECOPY(item->font,font_names[i]);
iniSetString(&inifile,itemname,"Font",item->font,&ini_style);
changed=1;
}
......@@ -1600,7 +1600,7 @@ struct bbslist *show_bbslist(char *current, int connected)
*p=')';
}
else
strncpy(title, syncterm_version, sizeof(title));
SAFECOPY(title, syncterm_version);
settitle(title);
}
oldopt=opt;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment