X-Git-Url: https://git.tokkee.org/?a=blobdiff_plain;f=wt-status.c;h=8836a527d0b1980bd4ebdd50b3225f7ce37ccf79;hb=48058f5df49fb9005418a7d025b374988908c0b5;hp=da4bce5816c1437c2f761db9d8aedbcb72aba019;hpb=f1c9626105d5e4962a5ccaa4620114d03f32ad02;p=git.git diff --git a/wt-status.c b/wt-status.c index da4bce581..8836a527d 100644 --- a/wt-status.c +++ b/wt-status.c @@ -26,7 +26,9 @@ static char default_wt_status_colors[][COLOR_MAXLEN] = { static const char *color(int slot, struct wt_status *s) { - const char *c = s->use_color > 0 ? s->color_palette[slot] : ""; + const char *c = ""; + if (want_color(s->use_color)) + c = s->color_palette[slot]; if (slot == WT_STATUS_ONBRANCH && color_is_nil(c)) c = s->color_palette[WT_STATUS_HEADER]; return c; @@ -642,7 +644,7 @@ static void wt_status_print_other(struct wt_status *s, int i; struct strbuf buf = STRBUF_INIT; - if (!s->untracked.nr) + if (!l->nr) return; wt_status_print_other_header(s, what, how);