comparison svr-chansession.c @ 1103:303e27a78d2e

Turn type local variable into char *
author Gaël PORTAY <gael.portay@gmail.com>
date Sun, 03 May 2015 01:12:24 +0200
parents ae63de5caf81
children 5eb00b6b9040
comparison
equal deleted inserted replaced
1102:ae63de5caf81 1103:303e27a78d2e
341 341
342 /* Handle requests for a channel. These can be execution requests, 342 /* Handle requests for a channel. These can be execution requests,
343 * or x11/authagent forwarding. These are passed to appropriate handlers */ 343 * or x11/authagent forwarding. These are passed to appropriate handlers */
344 static void chansessionrequest(struct Channel *channel) { 344 static void chansessionrequest(struct Channel *channel) {
345 345
346 unsigned char * type = NULL; 346 char * type = NULL;
347 unsigned int typelen; 347 unsigned int typelen;
348 unsigned char wantreply; 348 unsigned char wantreply;
349 int ret = 1; 349 int ret = 1;
350 struct ChanSess *chansess; 350 struct ChanSess *chansess;
351 351
352 TRACE(("enter chansessionrequest")) 352 TRACE(("enter chansessionrequest"))
353 353
354 type = buf_getstring(ses.payload, &typelen); 354 type = (char *) buf_getstring(ses.payload, &typelen);
355 wantreply = buf_getbool(ses.payload); 355 wantreply = buf_getbool(ses.payload);
356 356
357 if (typelen > MAX_NAME_LEN) { 357 if (typelen > MAX_NAME_LEN) {
358 TRACE(("leave chansessionrequest: type too long")) /* XXX send error?*/ 358 TRACE(("leave chansessionrequest: type too long")) /* XXX send error?*/
359 goto out; 359 goto out;