mirror of
git://git.code.sf.net/p/zsh/code
synced 2025-11-02 06:40:55 +01:00
Silenced one signed/unsigned comparison compiler warning.
This commit is contained in:
parent
b5d7902c20
commit
12b2ed63ab
5 changed files with 5 additions and 5 deletions
|
|
@ -431,7 +431,7 @@ zfunalarm(void)
|
|||
* I love the way alarm() uses unsigned int while time_t
|
||||
* is probably something completely different.
|
||||
*/
|
||||
time_t tdiff = time(NULL) - oaltime;
|
||||
unsigned int tdiff = time(NULL) - oaltime;
|
||||
alarm(oalremain < tdiff ? 1 : oalremain - tdiff);
|
||||
} else
|
||||
alarm(0);
|
||||
|
|
|
|||
|
|
@ -2892,7 +2892,7 @@ sep_comp_string(char *ss, char *s, int noffs)
|
|||
sl = strlen(s);
|
||||
if (swe > sl) {
|
||||
swe = sl;
|
||||
if (strlen(ns) > swe - swb + 1)
|
||||
if ((int)strlen(ns) > swe - swb + 1)
|
||||
ns[swe - swb + 1] = '\0';
|
||||
}
|
||||
qs = tricat(multiquote(s + swe, 0), qisuf, "");
|
||||
|
|
|
|||
|
|
@ -788,7 +788,7 @@ do_comp_vars(int test, int na, char *sa, int nb, char *sb, int mod)
|
|||
if (!na)
|
||||
return 1;
|
||||
if (na > 0 &&
|
||||
strlen(test == CVT_PRENUM ? compprefix : compsuffix) >= na) {
|
||||
(int)strlen(test == CVT_PRENUM ? compprefix : compsuffix) >= na) {
|
||||
if (mod) {
|
||||
if (test == CVT_PRENUM)
|
||||
ignore_prefix(na);
|
||||
|
|
|
|||
|
|
@ -808,7 +808,7 @@ doisearch(char **args, int dir)
|
|||
else
|
||||
pos -= 1 + (pos != 1 && s[pos-2] == Meta);
|
||||
} else if (sbuf[0] != '^') {
|
||||
if (pos >= strlen(s+1))
|
||||
if (pos >= (int)strlen(s+1))
|
||||
skip_line = 1;
|
||||
else
|
||||
pos += 1 + (s[pos] == Meta);
|
||||
|
|
|
|||
|
|
@ -1033,7 +1033,7 @@ tc_rightcurs(int ct)
|
|||
if we're anywhere in the prompt, goto the left column and write the whole
|
||||
prompt out unless ztrlen(lpromptbuf) == lpromptw : we can cheat then */
|
||||
if (vln == 0 && i < lpromptw && !(termflags & TERM_SHORT)) {
|
||||
if (strlen(lpromptbuf) == lpromptw)
|
||||
if ((int)strlen(lpromptbuf) == lpromptw)
|
||||
fputs(lpromptbuf + i, shout);
|
||||
else if (tccan(TCRIGHT) && (tclen[TCRIGHT] * ct <= ztrlen(lpromptbuf)))
|
||||
/* it is cheaper to send TCRIGHT than reprint the whole prompt */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue