• R/O
  • HTTP
  • SSH
  • HTTPS

Commit

Tags
Keine Tags

Frequently used words (click to add to your profile)

javac++androidlinuxc#windowsobjective-ccocoa誰得qtpythonphprubygameguibathyscaphec計画中(planning stage)翻訳omegatframeworktwitterdomtestvb.netdirectxゲームエンジンbtronarduinopreviewer

Commit MetaInfo

Revisionb858e80a02ca64b9208499155f4dab4ef298b523 (tree)
Zeit2020-01-20 23:11:39
AutorDaniel Henrique Barboza <danielhb413@gmai...>
CommiterGreg Kurz

Log Message

9pfs/9p.c: remove unneeded labels

'out' label in v9fs_xattr_write() and 'out_nofid' label in
v9fs_complete_rename() can be replaced by appropriate return
calls.

CC: Greg Kurz <groug@kaod.org>
Signed-off-by: Daniel Henrique Barboza <danielhb413@gmail.com>
Acked-by: Greg Kurz <groug@kaod.org>
Signed-off-by: Greg Kurz <groug@kaod.org>

Ändern Zusammenfassung

Diff

--- a/hw/9pfs/9p.c
+++ b/hw/9pfs/9p.c
@@ -2472,8 +2472,7 @@ static int v9fs_xattr_write(V9fsState *s, V9fsPDU *pdu, V9fsFidState *fidp,
24722472
24732473
24742474 if (fidp->fs.xattr.len < off) {
2475- err = -ENOSPC;
2476- goto out;
2475+ return -ENOSPC;
24772476 }
24782477 write_count = fidp->fs.xattr.len - off;
24792478 if (write_count > count) {
@@ -2499,7 +2498,7 @@ static int v9fs_xattr_write(V9fsState *s, V9fsPDU *pdu, V9fsFidState *fidp,
24992498 off += to_copy;
25002499 write_count -= to_copy;
25012500 }
2502-out:
2501+
25032502 return err;
25042503 }
25052504
@@ -3067,8 +3066,7 @@ static int coroutine_fn v9fs_complete_rename(V9fsPDU *pdu, V9fsFidState *fidp,
30673066 if (newdirfid != -1) {
30683067 dirfidp = get_fid(pdu, newdirfid);
30693068 if (dirfidp == NULL) {
3070- err = -ENOENT;
3071- goto out_nofid;
3069+ return -ENOENT;
30723070 }
30733071 if (fidp->fid_type != P9_FID_NONE) {
30743072 err = -EINVAL;
@@ -3111,7 +3109,6 @@ out:
31113109 put_fid(pdu, dirfidp);
31123110 }
31133111 v9fs_path_free(&new_path);
3114-out_nofid:
31153112 return err;
31163113 }
31173114