mirror of
https://github.com/weechat/weechat.git
synced 2026-06-26 21:06:38 +02:00
script: use "const char *" variables for result of string functions with const parameter
This commit is contained in:
@@ -184,7 +184,8 @@ script_action_run_list_input (struct t_gui_buffer *buffer,
|
||||
void
|
||||
script_action_run_load (const char *name, int quiet)
|
||||
{
|
||||
char *pos, str_command[1024];
|
||||
const char *pos;
|
||||
char str_command[1024];
|
||||
int language;
|
||||
|
||||
language = -1;
|
||||
@@ -227,8 +228,8 @@ script_action_run_load (const char *name, int quiet)
|
||||
void
|
||||
script_action_run_unload (const char *name, int quiet)
|
||||
{
|
||||
char *pos, hdata_name[128], *filename, *ptr_base_name, str_command[1024];
|
||||
const char *ptr_filename, *ptr_registered_name;
|
||||
char hdata_name[128], *filename, *ptr_base_name, str_command[1024];
|
||||
const char *pos, *ptr_filename, *ptr_registered_name;
|
||||
int language, found, i;
|
||||
struct t_hdata *hdata;
|
||||
void *ptr_script;
|
||||
@@ -332,8 +333,8 @@ script_action_run_unload (const char *name, int quiet)
|
||||
void
|
||||
script_action_run_reload (const char *name, int quiet)
|
||||
{
|
||||
char *pos, hdata_name[128], *filename, *ptr_base_name, str_command[1024];
|
||||
const char *ptr_filename, *ptr_registered_name;
|
||||
char hdata_name[128], *filename, *ptr_base_name, str_command[1024];
|
||||
const char *pos, *ptr_filename, *ptr_registered_name;
|
||||
int language, found, i;
|
||||
struct t_hdata *hdata;
|
||||
void *ptr_script;
|
||||
@@ -443,7 +444,8 @@ void
|
||||
script_action_run_autoload (const char *name, int quiet, int autoload)
|
||||
{
|
||||
struct t_script_repo *ptr_script;
|
||||
char *pos, str_signal[256], *weechat_data_dir, *filename;
|
||||
char str_signal[256], *weechat_data_dir, *filename;
|
||||
const char *pos;
|
||||
int language, script_found, script_autoloaded;
|
||||
struct stat st;
|
||||
|
||||
|
||||
@@ -156,8 +156,8 @@ void
|
||||
script_completion_exec_file_cb (void *data, const char *filename)
|
||||
{
|
||||
struct t_gui_completion *completion;
|
||||
const char *extension;
|
||||
char *pos, *filename2, *ptr_base_name;
|
||||
const char *extension, *pos;
|
||||
char *filename2, *ptr_base_name;
|
||||
|
||||
completion = (struct t_gui_completion *)(((void **)data)[0]);
|
||||
extension = (const char *)(((void **)data)[1]);
|
||||
|
||||
@@ -714,8 +714,7 @@ script_repo_remove_all (void)
|
||||
int
|
||||
script_repo_script_is_held (struct t_script_repo *script)
|
||||
{
|
||||
const char *hold;
|
||||
char *pos;
|
||||
const char *hold, *pos;
|
||||
int length;
|
||||
|
||||
hold = weechat_config_string (script_config_scripts_hold);
|
||||
|
||||
Reference in New Issue
Block a user