Permalink
Browse files

Unify the pointer casting style in my code.

Code from 1.8x are left for diff-friendly.
  • Loading branch information...
1 parent 13f0cd4 commit bc29a7782316619b08239339e6ce81a9286f0a32 @lichray committed Oct 10, 2012
Showing with 6 additions and 6 deletions.
  1. +1 −1 common/encoding.c
  2. +1 −1 common/exf.c
  3. +2 −2 vi/v_txt.c
  4. +2 −2 vi/vs_line.c
View
@@ -59,7 +59,7 @@ static char text_chars[256] = {
int
looks_utf8(const char *ibuf, size_t nbytes)
{
- const u_char *buf = (u_char*)ibuf;
+ const u_char *buf = (u_char *)ibuf;
size_t i;
int n;
int gotone = 0, ctrl = 0;
View
@@ -1263,7 +1263,7 @@ file_encinit(SCR *sp)
key.data = &lno;
key.size = sizeof(lno);
if (!ep->db->seq(ep->db, &key, &data, R_LAST) &&
- *(char*)data.data == '\0')
+ *(char *)data.data == '\0')
ep->db->del(ep->db, &key, 0);
o_set(sp, O_FILEENCODING, OS_STRDUP, "utf-16le", 0);
break;
View
@@ -2304,7 +2304,7 @@ txt_emark(SCR *sp, TEXT *tp, size_t cno)
for (cno += chlen; chlen--;)
*p++ = ' ';
else
- for (kp = (u_char*)
+ for (kp = (u_char *)
KEY_NAME(sp, tp->lb[cno]),
cno += chlen; chlen--;)
*p++ = *kp++;
@@ -2501,7 +2501,7 @@ txt_insch(SCR *sp, TEXT *tp, CHAR_T *chp, u_int flags)
for (p = tp->lb + cno + 1; chlen--;)
*p++ = ' ';
else
- for (kp = (u_char*)
+ for (kp = (u_char *)
KEY_NAME(sp, tp->lb[cno]) + nlen,
p = tp->lb + cno + 1; chlen--;)
*p++ = *kp++;
View
@@ -436,7 +436,7 @@ empty: (void)gp->scr_addstr(sp,
if (KEY_NEEDSWIDE(sp, ch))
*cbp++ = ch;
else
- for (kp = (u_char*)
+ for (kp = (u_char *)
KEY_NAME(sp, ch) + offset_in_char;
chlen--;)
*cbp++ = *kp++;
@@ -459,7 +459,7 @@ empty: (void)gp->scr_addstr(sp,
chlen = KEY_LEN(sp, '$');
if (cbp + chlen >= ecbp)
FLUSH;
- for (kp = (u_char*)
+ for (kp = (u_char *)
KEY_NAME(sp, '$'); chlen--;)
*cbp++ = *kp++;
}

0 comments on commit bc29a77

Please sign in to comment.