# session_has

- **Language:** C
- **Kind:** function
- **Source:** https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/session.c#L362
- **Page:** https://libtmux.org/en/tmux/3.7c/reference/c-function-session_has/

```c
int session_has(struct session *s, struct window *w)
```

## Parameters

- `s` (`struct session *`)
- `w` (`struct window *`)

## Called by

- [`cmd_find_best_session_with_window`](/en/tmux/3.7c/reference/c-function-cmd-find-c-cmd_find_best_session_with_window/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-find.c#L186)
- [`cmd_select_pane_redraw`](/en/tmux/3.7c/reference/c-function-cmd-select-pane-c-cmd_select_pane_redraw/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-select-pane.c#L76)
- [`recalculate_size_skip_client`](/en/tmux/3.7c/reference/c-function-resize-c-recalculate_size_skip_client/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/resize.c#L349)
- [`screen_write_set_client_cb`](/en/tmux/3.7c/reference/c-function-screen-write-c-screen_write_set_client_cb/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/screen-write.c#L139)
- [`server_kill_window`](/en/tmux/3.7c/reference/c-function-server_kill_window/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/server-fn.c#L206)
- [`server_status_window`](/en/tmux/3.7c/reference/c-function-server_status_window/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/server-fn.c#L131)

## Referenced by

- [`clients_with_window`](/en/tmux/3.7c/reference/c-function-resize-c-clients_with_window/) (function)
- [`cmd_find_get_window_with_session`](/en/tmux/3.7c/reference/c-function-cmd-find-c-cmd_find_get_window_with_session/) (function)
- [`default_window_size_skip_client`](/en/tmux/3.7c/reference/c-function-resize-c-default_window_size_skip_client/) (function)
- [`input_add_request`](/en/tmux/3.7c/reference/c-function-input-c-input_add_request/) (function)
- [`window_get_bg_client`](/en/tmux/3.7c/reference/c-function-window_get_bg_client/) (function)
- [`window_pane_get_fg`](/en/tmux/3.7c/reference/c-function-window_pane_get_fg/) (function)
- [`window_pane_get_theme`](/en/tmux/3.7c/reference/c-function-window_pane_get_theme/) (function)

## Referenced declarations

- [`session`](/en/tmux/3.7c/reference/c-struct-session/) (struct)
- [`winlink.session`](/en/tmux/3.7c/reference/c-struct-winlink-session/) (attribute)
- [`winlink.wentry`](/en/tmux/3.7c/reference/c-struct-winlink-wentry/) (attribute)
- [`window`](/en/tmux/3.7c/reference/c-struct-window/) (struct)
- [`window.winlinks`](/en/tmux/3.7c/reference/c-struct-window-winlinks/) (attribute)
