mirror of
git://git.code.sf.net/p/zsh/code
synced 2025-01-01 05:16:05 +01:00
37868: add 'static' to file local variables
This commit is contained in:
parent
69acac38c9
commit
a4020e10a3
16 changed files with 34 additions and 27 deletions
|
@ -1,3 +1,11 @@
|
|||
2016-02-03 Jun-ichi Takimoto <takimoto-j@kba.biglobe.ne.jp>
|
||||
|
||||
* 37868: Src/Modules/curses.c, Src/Modules/param_private.c,
|
||||
Src/Modules/tcp.c, Src/Modules/termcap.c, Src/Modules/zftp.c,
|
||||
Src/Zle/complist.c, Src/Zle/zle_misc.c, Src/Zle/zle_utils.c,
|
||||
Src/cond.c, Src/exec.c, Src/glob.c, Src/jobs.c, Src/params.c,
|
||||
Src/prompt.c, Src/utils.c: add 'static' to file local variables.
|
||||
|
||||
2016-01-31 Barton E. Schaefer <schaefer@zsh.org>
|
||||
|
||||
* 37859: Src/text.c: NULL-terminate cond_binary_ops static array.
|
||||
|
|
|
@ -202,7 +202,7 @@ static const struct zcurses_mouse_event zcurses_mouse_map[] = {
|
|||
{ 0, 0, 0 }
|
||||
};
|
||||
|
||||
mmask_t zcurses_mouse_mask = ALL_MOUSE_EVENTS;
|
||||
static mmask_t zcurses_mouse_mask = ALL_MOUSE_EVENTS;
|
||||
|
||||
#endif
|
||||
|
||||
|
|
|
@ -42,19 +42,19 @@ struct gsu_closure {
|
|||
void *g;
|
||||
};
|
||||
|
||||
const struct gsu_scalar scalar_private_gsu =
|
||||
static const struct gsu_scalar scalar_private_gsu =
|
||||
{ pps_getfn, pps_setfn, pps_unsetfn };
|
||||
|
||||
const struct gsu_integer integer_private_gsu =
|
||||
static const struct gsu_integer integer_private_gsu =
|
||||
{ ppi_getfn, ppi_setfn, ppi_unsetfn };
|
||||
|
||||
const struct gsu_float float_private_gsu =
|
||||
static const struct gsu_float float_private_gsu =
|
||||
{ ppf_getfn, ppf_setfn, ppf_unsetfn };
|
||||
|
||||
const struct gsu_array array_private_gsu =
|
||||
static const struct gsu_array array_private_gsu =
|
||||
{ ppa_getfn, ppa_setfn, ppa_unsetfn };
|
||||
|
||||
const struct gsu_hash hash_private_gsu =
|
||||
static const struct gsu_hash hash_private_gsu =
|
||||
{ pph_getfn, pph_setfn, pph_unsetfn };
|
||||
|
||||
/*
|
||||
|
|
|
@ -208,7 +208,7 @@ freehostent(UNUSED(struct hostent *ptr))
|
|||
/**/
|
||||
#endif /* !HAVE_GETIPNODEBYNAME */
|
||||
|
||||
LinkList ztcp_sessions;
|
||||
static LinkList ztcp_sessions;
|
||||
|
||||
/* "allocate" a tcp_session */
|
||||
static Tcp_session
|
||||
|
|
|
@ -295,7 +295,7 @@ scantermcap(UNUSED(HashTable ht), ScanFunc func, int flags)
|
|||
}
|
||||
}
|
||||
|
||||
struct paramdef partab[] = {
|
||||
static struct paramdef partab[] = {
|
||||
SPECIALPMDEF("termcap", PM_READONLY, NULL, gettermcap, scantermcap)
|
||||
};
|
||||
|
||||
|
|
|
@ -344,10 +344,10 @@ static int zfsesscnt;
|
|||
*/
|
||||
|
||||
/* flags for alarm set, alarm gone off */
|
||||
int zfalarmed, zfdrrrring;
|
||||
static int zfalarmed, zfdrrrring;
|
||||
/* remember old alarm status */
|
||||
time_t oaltime;
|
||||
unsigned int oalremain;
|
||||
static time_t oaltime;
|
||||
static unsigned int oalremain;
|
||||
|
||||
/*
|
||||
* Where to jump to when the alarm goes off. This is much
|
||||
|
@ -357,7 +357,7 @@ unsigned int oalremain;
|
|||
*
|
||||
* gcc -O gives apparently spurious `may be clobbered by longjmp' warnings.
|
||||
*/
|
||||
jmp_buf zfalrmbuf;
|
||||
static jmp_buf zfalrmbuf;
|
||||
|
||||
/* The signal handler itself */
|
||||
|
||||
|
|
|
@ -113,7 +113,7 @@ static Cmgroup *mgtab, *mgtabp;
|
|||
* Allow us to keep track of pointer arithmetic for mgtab; could
|
||||
* just as well have been for mtab but wasn't.
|
||||
*/
|
||||
int mgtabsize;
|
||||
static int mgtabsize;
|
||||
#endif
|
||||
|
||||
/*
|
||||
|
|
|
@ -1497,7 +1497,7 @@ struct suffixset {
|
|||
};
|
||||
|
||||
/* The list of suffix structures */
|
||||
struct suffixset *suffixlist;
|
||||
static struct suffixset *suffixlist;
|
||||
|
||||
/* Shell function to call to remove the suffix. */
|
||||
|
||||
|
|
|
@ -587,7 +587,7 @@ struct zle_position {
|
|||
};
|
||||
|
||||
/* LIFO stack of positions */
|
||||
struct zle_position *zle_positions;
|
||||
static struct zle_position *zle_positions;
|
||||
|
||||
/*
|
||||
* Save positions including cursor, end-of-line and
|
||||
|
@ -1412,7 +1412,7 @@ zlong undo_changeno;
|
|||
|
||||
/* If positive, don't undo beyond this point */
|
||||
|
||||
zlong undo_limitno;
|
||||
static zlong undo_limitno;
|
||||
|
||||
/**/
|
||||
void
|
||||
|
|
|
@ -30,7 +30,8 @@
|
|||
#include "zsh.mdh"
|
||||
#include "cond.pro"
|
||||
|
||||
int tracingcond;
|
||||
/**/
|
||||
int tracingcond; /* updated by execcond() in exec.c */
|
||||
|
||||
static char *condstr[COND_MOD] = {
|
||||
"!", "&&", "||", "==", "!=", "<", ">", "-nt", "-ot", "-ef", "-eq",
|
||||
|
|
|
@ -4518,8 +4518,6 @@ spawnpipes(LinkList l, int nullexec)
|
|||
}
|
||||
}
|
||||
|
||||
extern int tracingcond;
|
||||
|
||||
/* evaluate a [[ ... ]] */
|
||||
|
||||
/**/
|
||||
|
|
|
@ -306,7 +306,7 @@ statfullpath(const char *s, struct stat *st, int l)
|
|||
/* This may be set by qualifier functions to an array of strings to insert
|
||||
* into the list instead of the original string. */
|
||||
|
||||
char **inserts;
|
||||
static char **inserts;
|
||||
|
||||
/* add a match to the list */
|
||||
|
||||
|
|
|
@ -1970,9 +1970,9 @@ struct bgstatus {
|
|||
};
|
||||
typedef struct bgstatus *Bgstatus;
|
||||
/* The list of those entries */
|
||||
LinkList bgstatus_list;
|
||||
static LinkList bgstatus_list;
|
||||
/* Count of entries. Reaches value of _SC_CHILD_MAX and stops. */
|
||||
long bgstatus_count;
|
||||
static long bgstatus_count;
|
||||
|
||||
/*
|
||||
* Remove and free a bgstatus entry.
|
||||
|
@ -2372,7 +2372,7 @@ bin_fg(char *name, char **argv, Options ops, int func)
|
|||
return retval;
|
||||
}
|
||||
|
||||
const struct {
|
||||
static const struct {
|
||||
const char *name;
|
||||
int num;
|
||||
} alt_sigs[] = {
|
||||
|
|
|
@ -416,7 +416,7 @@ IPDEF10("pipestatus", pipestatus_gsu),
|
|||
* and $@, this is not readonly. This parameter is not directly
|
||||
* visible in user space.
|
||||
*/
|
||||
initparam argvparam_pm = IPDEF9F("", &pparams, NULL, \
|
||||
static initparam argvparam_pm = IPDEF9F("", &pparams, NULL, \
|
||||
PM_ARRAY|PM_SPECIAL|PM_DONTIMPORT);
|
||||
|
||||
#undef BR
|
||||
|
|
|
@ -1831,7 +1831,7 @@ struct colour_sequences {
|
|||
char *end; /* Escape sequence terminator */
|
||||
char *def; /* Code to reset default colour */
|
||||
};
|
||||
struct colour_sequences fg_bg_sequences[2];
|
||||
static struct colour_sequences fg_bg_sequences[2];
|
||||
|
||||
/*
|
||||
* We need a buffer for colour sequence composition. It may
|
||||
|
|
|
@ -56,12 +56,12 @@ typedef struct widechar_array *Widechar_array;
|
|||
* The wordchars variable turned into a wide character array.
|
||||
* This is much more convenient for testing.
|
||||
*/
|
||||
struct widechar_array wordchars_wide;
|
||||
static struct widechar_array wordchars_wide;
|
||||
|
||||
/*
|
||||
* The same for the separators (IFS) array.
|
||||
*/
|
||||
struct widechar_array ifs_wide;
|
||||
static struct widechar_array ifs_wide;
|
||||
|
||||
/* Function to set one of the above from the multibyte array */
|
||||
|
||||
|
|
Loading…
Reference in a new issue