mirror of
https://git.tartarus.org/simon/putty.git
synced 2025-07-20 20:31:34 -05:00
Make the backend_init error message dynamic. (NFC)
Now, instead of a 'const char *' in the static data segment, error messages returned from backend setup are dynamically allocated and freed by the caller. This will allow me to make the messages much more specific (including errno values and the like). However, this commit is pure refactoring: I've _just_ changed the allocation policy, and left all the messages alone.
This commit is contained in:
@ -1270,10 +1270,10 @@ Backend *pty_backend_create(
|
||||
* it gets the argv array from the global variable pty_argv, expecting
|
||||
* that it will have been invoked by pterm.
|
||||
*/
|
||||
static const char *pty_init(const BackendVtable *vt, Seat *seat,
|
||||
Backend **backend_handle, LogContext *logctx,
|
||||
Conf *conf, const char *host, int port,
|
||||
char **realhost, bool nodelay, bool keepalive)
|
||||
static char *pty_init(const BackendVtable *vt, Seat *seat,
|
||||
Backend **backend_handle, LogContext *logctx,
|
||||
Conf *conf, const char *host, int port,
|
||||
char **realhost, bool nodelay, bool keepalive)
|
||||
{
|
||||
const char *cmd = NULL;
|
||||
struct ssh_ttymodes modes;
|
||||
|
Reference in New Issue
Block a user