From: Eric V. H. <er...@us...> - 2005-04-29 15:39:54
|
Update of /cvsroot/v9fs/linux-9p In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv14304/linux-9p Modified Files: 9p.h CHANGELOG conv.c trans_sock.c Log Message: Protocol field shifting to help port to p9p Index: 9p.h =================================================================== RCS file: /cvsroot/v9fs/linux-9p/9p.h,v retrieving revision 1.15 retrieving revision 1.16 diff -C2 -d -r1.15 -r1.16 *** 9p.h 22 Apr 2005 21:47:01 -0000 1.15 --- 9p.h 29 Apr 2005 15:39:45 -0000 1.16 *************** *** 116,122 **** uint32_t mtime; uint64_t length; - uint32_t n_uid; /* 9p2000.u extensions */ - uint32_t n_gid; /* 9p2000.u extensions */ - uint32_t n_muid; /* 9p2000.u extensions */ char *name; char *uid; --- 116,119 ---- *************** *** 124,127 **** --- 121,127 ---- char *muid; char *extension; /* 9p2000.u extensions */ + uint32_t n_uid; /* 9p2000.u extensions */ + uint32_t n_gid; /* 9p2000.u extensions */ + uint32_t n_muid; /* 9p2000.u extensions */ char data[0]; }; Index: trans_sock.c =================================================================== RCS file: /cvsroot/v9fs/linux-9p/trans_sock.c,v retrieving revision 1.18 retrieving revision 1.19 diff -C2 -d -r1.18 -r1.19 *** trans_sock.c 28 Apr 2005 15:41:01 -0000 1.18 --- trans_sock.c 29 Apr 2005 15:39:45 -0000 1.19 *************** *** 153,159 **** struct sockaddr_in sin_server; int rc = 0; ! struct v9fs_trans_sock *ts; ! char *addr; ! int port; sema_init(&trans->writelock, 1); --- 153,159 ---- struct sockaddr_in sin_server; int rc = 0; ! struct v9fs_trans_sock *ts = NULL; ! char *addr = NULL; ! int port = 564; sema_init(&trans->writelock, 1); *************** *** 185,189 **** sizeof(struct sockaddr_in), 0); if (rc < 0) { - ts->s = NULL; eprintk(KERN_ERR, "v9fs_trans_tcp: problem connecting socket to %s\n", --- 185,188 ---- Index: conv.c =================================================================== RCS file: /cvsroot/v9fs/linux-9p/conv.c,v retrieving revision 1.17 retrieving revision 1.18 diff -C2 -d -r1.17 -r1.18 *** conv.c 22 Apr 2005 20:28:35 -0000 1.17 --- conv.c 29 Apr 2005 15:39:45 -0000 1.18 *************** *** 286,290 **** 4 + /* mtime[4] */ 8 + /* length[8] */ ! 8; /* minimum sum of string lengths */ if (stat->name) --- 286,290 ---- 4 + /* mtime[4] */ 8 + /* length[8] */ ! 8; /* minimum sum of string lengths */ if (stat->name) *************** *** 332,341 **** buf_put_int64(bufp, stat->length); - if (v9ses->extended) { - buf_put_int32(bufp, stat->n_uid); - buf_put_int32(bufp, stat->n_gid); - buf_put_int32(bufp, stat->n_muid); - } - buf_put_string(bufp, stat->name); buf_put_string(bufp, stat->uid); --- 332,335 ---- *************** *** 343,349 **** buf_put_string(bufp, stat->muid); ! if (v9ses->extended) buf_put_string(bufp, stat->extension); ! if (buf_check_overflow(bufp)) --- 337,346 ---- buf_put_string(bufp, stat->muid); ! if (v9ses->extended) { buf_put_string(bufp, stat->extension); ! buf_put_int32(bufp, stat->n_uid); ! buf_put_int32(bufp, stat->n_gid); ! buf_put_int32(bufp, stat->n_muid); ! } if (buf_check_overflow(bufp)) *************** *** 398,413 **** stat->mtime = buf_get_int32(bufp); stat->length = buf_get_int64(bufp); - if (v9ses->extended) { - stat->n_uid = buf_get_int32(bufp); - stat->n_gid = buf_get_int32(bufp); - stat->n_muid = buf_get_int32(bufp); - } stat->name = buf_get_stringb(bufp, dbufp); stat->uid = buf_get_stringb(bufp, dbufp); stat->gid = buf_get_stringb(bufp, dbufp); stat->muid = buf_get_stringb(bufp, dbufp); - if (v9ses->extended) - stat->extension = buf_get_stringb(bufp, dbufp); if (buf_check_overflow(bufp) || buf_check_overflow(dbufp)) --- 395,409 ---- stat->mtime = buf_get_int32(bufp); stat->length = buf_get_int64(bufp); stat->name = buf_get_stringb(bufp, dbufp); stat->uid = buf_get_stringb(bufp, dbufp); stat->gid = buf_get_stringb(bufp, dbufp); stat->muid = buf_get_stringb(bufp, dbufp); + if (v9ses->extended) { + stat->extension = buf_get_stringb(bufp, dbufp); + stat->n_uid = buf_get_int32(bufp); + stat->n_gid = buf_get_int32(bufp); + stat->n_muid = buf_get_int32(bufp); + } if (buf_check_overflow(bufp) || buf_check_overflow(dbufp)) Index: CHANGELOG =================================================================== RCS file: /cvsroot/v9fs/linux-9p/CHANGELOG,v retrieving revision 1.42 retrieving revision 1.43 diff -C2 -d -r1.42 -r1.43 *** CHANGELOG 28 Apr 2005 15:41:01 -0000 1.42 --- CHANGELOG 29 Apr 2005 15:39:45 -0000 1.43 *************** *** 1,2 **** --- 1,5 ---- + ====== 04/29/2005 - ericvh ==== + * protocol field shifting for lucho - make sure you update u9fs too + ====== 04/28/2005 - ericvh ==== * fix memory leaks in transport and session_init |