Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/external/bsd/tmux merge conflicts, fix build.



details:   https://anonhg.NetBSD.org/src/rev/16e648dc93d7
branches:  trunk
changeset: 330855:16e648dc93d7
user:      christos <christos%NetBSD.org@localhost>
date:      Thu Jul 24 15:09:24 2014 +0000

description:
merge conflicts, fix build.

diffstat:

 external/bsd/tmux/dist/client.c              |     2 +-
 external/bsd/tmux/dist/cmd-capture-pane.c    |     2 +-
 external/bsd/tmux/dist/cmd-choose-session.c  |   156 --
 external/bsd/tmux/dist/cmd-choose-window.c   |   169 ---
 external/bsd/tmux/dist/cmd-display-message.c |    80 +-
 external/bsd/tmux/dist/cmd-if-shell.c        |   136 +-
 external/bsd/tmux/dist/cmd-paste-buffer.c    |    58 +-
 external/bsd/tmux/dist/cmd-send-keys.c       |     4 +-
 external/bsd/tmux/dist/cmd-send-prefix.c     |    54 -
 external/bsd/tmux/dist/cmd-server-info.c     |   185 ---
 external/bsd/tmux/dist/cmd-show-buffer.c     |   109 --
 external/bsd/tmux/dist/cmd-show-messages.c   |     2 +-
 external/bsd/tmux/dist/cmd-start-server.c    |    44 -
 external/bsd/tmux/dist/cmd-string.c          |   113 +-
 external/bsd/tmux/dist/cmd-wait-for.c        |     4 +-
 external/bsd/tmux/dist/colour.c              |    73 +-
 external/bsd/tmux/dist/compat/imsg-buffer.c  |     3 +-
 external/bsd/tmux/dist/compat/imsg.c         |     3 +-
 external/bsd/tmux/dist/environ.c             |    23 +-
 external/bsd/tmux/dist/format.c              |     2 +-
 external/bsd/tmux/dist/grid-utf8.c           |    96 -
 external/bsd/tmux/dist/grid.c                |     2 +-
 external/bsd/tmux/dist/input-keys.c          |    58 +-
 external/bsd/tmux/dist/input.c               |   442 ++++++--
 external/bsd/tmux/dist/job.c                 |    48 +-
 external/bsd/tmux/dist/log.c                 |    78 +-
 external/bsd/tmux/dist/options.c             |    82 +-
 external/bsd/tmux/dist/screen-write.c        |   387 ++----
 external/bsd/tmux/dist/screen.c              |    46 +-
 external/bsd/tmux/dist/server-fn.c           |   184 ++-
 external/bsd/tmux/dist/session.c             |   153 +-
 external/bsd/tmux/dist/status.c              |     2 +-
 external/bsd/tmux/dist/tmux.1                |  1416 ++++++++++++++++++++-----
 external/bsd/tmux/dist/tmux.c                |   143 +-
 external/bsd/tmux/dist/tmux.h                |   908 ++++++++++-----
 external/bsd/tmux/dist/tty-acs.c             |    66 +-
 external/bsd/tmux/dist/tty-keys.c            |   932 ++++++++++------
 external/bsd/tmux/dist/tty-term.c            |    40 +-
 external/bsd/tmux/dist/window-copy.c         |   569 +++++++---
 external/bsd/tmux/dist/window.c              |   422 +++++-
 external/bsd/tmux/usr.bin/tmux/Makefile      |   118 +-
 41 files changed, 4402 insertions(+), 3012 deletions(-)

diffs (truncated from 12433 to 300 lines):

diff -r 756a08dde74e -r 16e648dc93d7 external/bsd/tmux/dist/client.c
--- a/external/bsd/tmux/dist/client.c   Thu Jul 24 15:03:30 2014 +0000
+++ b/external/bsd/tmux/dist/client.c   Thu Jul 24 15:09:24 2014 +0000
@@ -374,7 +374,7 @@
        int     retval;
 
        retval = imsg_compose(&client_ibuf, type, PROTOCOL_VERSION, -1, fd,
-           (void*)buf, len);
+           __UNCONST(buf), len);
        if (retval != 1)
                return (-1);
        return (0);
diff -r 756a08dde74e -r 16e648dc93d7 external/bsd/tmux/dist/cmd-capture-pane.c
--- a/external/bsd/tmux/dist/cmd-capture-pane.c Thu Jul 24 15:03:30 2014 +0000
+++ b/external/bsd/tmux/dist/cmd-capture-pane.c Thu Jul 24 15:09:24 2014 +0000
@@ -65,7 +65,7 @@
        if (wp->ictx.since_ground == NULL)
                return (xstrdup(""));
 
-       line = EVBUFFER_DATA(wp->ictx.since_ground);
+       line = (char *)EVBUFFER_DATA(wp->ictx.since_ground);
        linelen = EVBUFFER_LENGTH(wp->ictx.since_ground);
 
        buf = xstrdup("");
diff -r 756a08dde74e -r 16e648dc93d7 external/bsd/tmux/dist/cmd-choose-session.c
--- a/external/bsd/tmux/dist/cmd-choose-session.c       Thu Jul 24 15:03:30 2014 +0000
+++ /dev/null   Thu Jan 01 00:00:00 1970 +0000
@@ -1,156 +0,0 @@
-/* $Id: cmd-choose-session.c,v 1.1.1.2 2011/08/17 18:40:04 jmmv Exp $ */
-
-/*
- * Copyright (c) 2009 Nicholas Marriott <nicm%users.sourceforge.net@localhost>
- *
- * Permission to use, copy, modify, and distribute this software for any
- * purpose with or without fee is hereby granted, provided that the above
- * copyright notice and this permission notice appear in all copies.
- *
- * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
- * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
- * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
- * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
- * WHATSOEVER RESULTING FROM LOSS OF MIND, USE, DATA OR PROFITS, WHETHER
- * IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING
- * OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
- */
-
-#include <sys/types.h>
-
-#include <ctype.h>
-
-#include "tmux.h"
-
-/*
- * Enter choice mode to choose a session.
- */
-
-int    cmd_choose_session_exec(struct cmd *, struct cmd_ctx *);
-
-void   cmd_choose_session_callback(void *, int);
-void   cmd_choose_session_free(void *);
-
-const struct cmd_entry cmd_choose_session_entry = {
-       "choose-session", NULL,
-       "t:", 0, 1,
-       CMD_TARGET_WINDOW_USAGE " [template]",
-       0,
-       NULL,
-       NULL,
-       cmd_choose_session_exec
-};
-
-struct cmd_choose_session_data {
-       struct client   *client;
-       char            *template;
-};
-
-int
-cmd_choose_session_exec(struct cmd *self, struct cmd_ctx *ctx)
-{
-       struct args                     *args = self->args;
-       struct cmd_choose_session_data  *cdata;
-       struct winlink                  *wl;
-       struct session                  *s;
-       struct session_group            *sg;
-       u_int                            idx, sgidx, cur;
-       char                             tmp[64];
-
-       if (ctx->curclient == NULL) {
-               ctx->error(ctx, "must be run interactively");
-               return (-1);
-       }
-
-       if ((wl = cmd_find_window(ctx, args_get(args, 't'), NULL)) == NULL)
-               return (-1);
-
-       if (window_pane_set_mode(wl->window->active, &window_choose_mode) != 0)
-               return (0);
-
-       cur = idx = 0;
-       RB_FOREACH(s, sessions, &sessions) {
-               if (s == ctx->curclient->session)
-                       cur = idx;
-               idx++;
-
-               sg = session_group_find(s);
-               if (sg == NULL)
-                       *tmp = '\0';
-               else {
-                       sgidx = session_group_index(sg);
-                       xsnprintf(tmp, sizeof tmp, " (group %u)", sgidx);
-               }
-
-               window_choose_add(wl->window->active, s->idx,
-                   "%s: %u windows [%ux%u]%s%s", s->name,
-                   winlink_count(&s->windows), s->sx, s->sy,
-                   tmp, s->flags & SESSION_UNATTACHED ? "" : " (attached)");
-       }
-
-       cdata = xmalloc(sizeof *cdata);
-       if (args->argc != 0)
-               cdata->template = xstrdup(args->argv[0]);
-       else
-               cdata->template = xstrdup("switch-client -t '%%'");
-       cdata->client = ctx->curclient;
-       cdata->client->references++;
-
-       window_choose_ready(wl->window->active,
-           cur, cmd_choose_session_callback, cmd_choose_session_free, cdata);
-
-       return (0);
-}
-
-void
-cmd_choose_session_callback(void *data, int idx)
-{
-       struct cmd_choose_session_data  *cdata = data;
-       struct session                  *s;
-       struct cmd_list                 *cmdlist;
-       struct cmd_ctx                   ctx;
-       char                            *template, *cause;
-
-       if (idx == -1)
-               return;
-       if (cdata->client->flags & CLIENT_DEAD)
-               return;
-
-       s = session_find_by_index(idx);
-       if (s == NULL)
-               return;
-       template = cmd_template_replace(cdata->template, s->name, 1);
-
-       if (cmd_string_parse(template, &cmdlist, &cause) != 0) {
-               if (cause != NULL) {
-                       *cause = toupper((u_char) *cause);
-                       status_message_set(cdata->client, "%s", cause);
-                       xfree(cause);
-               }
-               xfree(template);
-               return;
-       }
-       xfree(template);
-
-       ctx.msgdata = NULL;
-       ctx.curclient = cdata->client;
-
-       ctx.error = key_bindings_error;
-       ctx.print = key_bindings_print;
-       ctx.info = key_bindings_info;
-
-       ctx.cmdclient = NULL;
-
-       cmd_list_exec(cmdlist, &ctx);
-       cmd_list_free(cmdlist);
-}
-
-void
-cmd_choose_session_free(void *data)
-{
-       struct cmd_choose_session_data  *cdata = data;
-
-       cdata->client->references--;
-       xfree(cdata->template);
-       xfree(cdata);
-}
diff -r 756a08dde74e -r 16e648dc93d7 external/bsd/tmux/dist/cmd-choose-window.c
--- a/external/bsd/tmux/dist/cmd-choose-window.c        Thu Jul 24 15:03:30 2014 +0000
+++ /dev/null   Thu Jan 01 00:00:00 1970 +0000
@@ -1,169 +0,0 @@
-/* $Id: cmd-choose-window.c,v 1.1.1.2 2011/08/17 18:40:04 jmmv Exp $ */
-
-/*
- * Copyright (c) 2009 Nicholas Marriott <nicm%users.sourceforge.net@localhost>
- *
- * Permission to use, copy, modify, and distribute this software for any
- * purpose with or without fee is hereby granted, provided that the above
- * copyright notice and this permission notice appear in all copies.
- *
- * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
- * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
- * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
- * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
- * WHATSOEVER RESULTING FROM LOSS OF MIND, USE, DATA OR PROFITS, WHETHER
- * IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING
- * OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
- */
-
-#include <sys/types.h>
-
-#include <ctype.h>
-
-#include "tmux.h"
-
-/*
- * Enter choice mode to choose a window.
- */
-
-int    cmd_choose_window_exec(struct cmd *, struct cmd_ctx *);
-
-void   cmd_choose_window_callback(void *, int);
-void   cmd_choose_window_free(void *);
-
-const struct cmd_entry cmd_choose_window_entry = {
-       "choose-window", NULL,
-       "t:", 0, 1,
-       CMD_TARGET_WINDOW_USAGE " [template]",
-       0,
-       NULL,
-       NULL,
-       cmd_choose_window_exec
-};
-
-struct cmd_choose_window_data {
-       struct client   *client;
-       struct session  *session;
-       char            *template;
-};
-
-int
-cmd_choose_window_exec(struct cmd *self, struct cmd_ctx *ctx)
-{
-       struct args                     *args = self->args;
-       struct cmd_choose_window_data   *cdata;
-       struct session                  *s;
-       struct winlink                  *wl, *wm;
-       struct window                   *w;
-       u_int                            idx, cur;
-       char                            *flags, *title;
-       const char                      *left, *right;
-
-       if (ctx->curclient == NULL) {
-               ctx->error(ctx, "must be run interactively");
-               return (-1);
-       }
-       s = ctx->curclient->session;
-
-       if ((wl = cmd_find_window(ctx, args_get(args, 't'), NULL)) == NULL)
-               return (-1);
-
-       if (window_pane_set_mode(wl->window->active, &window_choose_mode) != 0)
-               return (0);
-
-       cur = idx = 0;
-       RB_FOREACH(wm, winlinks, &s->windows) {
-               w = wm->window;
-
-               if (wm == s->curw)
-                       cur = idx;
-               idx++;
-
-               flags = window_printable_flags(s, wm);
-               title = w->active->screen->title;
-               if (wm == wl)
-                       title = w->active->base.title;
-               left = " \"";
-               right = "\"";
-               if (*title == '\0')
-                       left = right = "";
-
-               window_choose_add(wl->window->active,
-                   wm->idx, "%3d: %s%s [%ux%u] (%u panes%s)%s%s%s",
-                   wm->idx, w->name, flags, w->sx, w->sy, window_count_panes(w),
-                   w->active->fd == -1 ? ", dead" : "",
-                   left, title, right);
-
-               xfree(flags);
-       }
-
-       cdata = xmalloc(sizeof *cdata);
-       if (args->argc != 0)
-               cdata->template = xstrdup(args->argv[0]);
-       else
-               cdata->template = xstrdup("select-window -t '%%'");
-       cdata->session = s;
-       cdata->session->references++;
-       cdata->client = ctx->curclient;
-       cdata->client->references++;
-
-       window_choose_ready(wl->window->active,
-           cur, cmd_choose_window_callback, cmd_choose_window_free, cdata);
-



Home | Main Index | Thread Index | Old Index