# cmd_find_get_window_with_session

- **Language:** C
- **Kind:** function
- **Source:** https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-find.c#L348
- **Page:** https://libtmux.org/en/tmux/latest/reference/c-function-cmd-find-c-cmd_find_get_window_with_session/

```c
static int cmd_find_get_window_with_session(struct cmd_find_state *, const char *)
```

## Parameters

- `fs` (`struct cmd_find_state *`)
- `window` (`const char *`)

## Called by

- [`cmd_find_get_window`](/en/tmux/latest/reference/c-function-cmd-find-c-cmd_find_get_window/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-find.c#L328)
- [`cmd_find_target`](/en/tmux/latest/reference/c-function-cmd_find_target/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-find.c#L1161)

## Calls

- [`cmd_find_best_winlink_with_window`](/en/tmux/latest/reference/c-function-cmd-find-c-cmd_find_best_winlink_with_window/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-find.c#L370)
- [`log_debug`](/en/tmux/latest/reference/c-function-log_debug/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-find.c#L355)
- [`strtonum`](/en/tmux/latest/reference/c-function-strtonum/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-find.c#L376)
- [`window_find_by_id_str`](/en/tmux/latest/reference/c-function-window_find_by_id_str/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-find.c#L367)
- [`winlink_find_by_index`](/en/tmux/latest/reference/c-function-winlink_find_by_index/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-find.c#L433)
- [`winlink_next_by_number`](/en/tmux/latest/reference/c-function-winlink_next_by_number/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-find.c#L393)
- [`winlink_previous_by_number`](/en/tmux/latest/reference/c-function-winlink_previous_by_number/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-find.c#L395)

## Other function references

- [`session_has`](/en/tmux/latest/reference/c-function-session_has/) (function)

## Referenced declarations

- [`CMD_FIND_EXACT_WINDOW`](/en/tmux/latest/reference/c-define-tmux-h-cmd_find_exact_window/) (constant)
- [`cmd_find_state`](/en/tmux/latest/reference/c-struct-cmd_find_state/) (struct)
- [`CMD_FIND_WINDOW_INDEX`](/en/tmux/latest/reference/c-define-tmux-h-cmd_find_window_index/) (constant)
- [`session.curw`](/en/tmux/latest/reference/c-struct-session-curw/) (attribute)
- [`cmd_find_state.flags`](/en/tmux/latest/reference/c-struct-cmd_find_state-flags/) (attribute)
- [`cmd_find_state.idx`](/en/tmux/latest/reference/c-struct-cmd_find_state-idx/) (attribute)
- [`winlink.idx`](/en/tmux/latest/reference/c-struct-winlink-idx/) (attribute)
- [`session.lastw`](/en/tmux/latest/reference/c-struct-session-lastw/) (attribute)
- [`window.name`](/en/tmux/latest/reference/c-struct-window-name/) (attribute)
- [`cmd_find_state.s`](/en/tmux/latest/reference/c-struct-cmd_find_state-s/) (attribute)
- [`cmd_find_state.w`](/en/tmux/latest/reference/c-struct-cmd_find_state-w/) (attribute)
- [`winlink.window`](/en/tmux/latest/reference/c-struct-winlink-window/) (attribute)
- [`session.windows`](/en/tmux/latest/reference/c-struct-session-windows/) (attribute)
- [`cmd_find_state.wl`](/en/tmux/latest/reference/c-struct-cmd_find_state-wl/) (attribute)
