Skip to contentSkip to conversation

ocfs2: clean up an unuseful goto in ocfs2_put_slot function

PATCH New Guozhonghua 2 participants 2 messages Apr 7, 2016 – Apr 11, 2016 OCFS2

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 ocfs2: clean up an unuseful goto in ocfs2_put_slot function

The goto is not useful in the function ocfs2_put_slot, so delete it.

slot_map.c 2016-04-07 16:53:25.540793954 +0800 renamed from slot_map.c 2016-03-25 15:29:22.175343770 +0800 +2 -6
@@ -535,12 +535,9 @@ void ocfs2_put_slot(struct ocfs2_super *
        spin_unlock(&osb->osb_lock);
 
        status = ocfs2_update_disk_slot(osb, si, slot_num);
-       if (status < 0) {
+       if (status < 0)
                mlog_errno(status);
-               goto bail;
-       }
-
-bail:
+
        ocfs2_free_slot_info(osb);
 }
-------------------------------------------------------------------------------------------------------------------------------------

???????????????????????????????????????? ???????????????????????????????????????? ????????????????????????????????????????
???
This e-mail and its attachments contain confidential information from H3C, which is intended only for the person or entity whose address is listed above. Any use of the information contained herein in any way (including, but not limited to, total or partial disclosure, reproduction, or dissemination) by persons other than the intended recipient(s) is prohibited. If you receive this e-mail in error, please notify the sender by phone or email immediately and delete it!

#1 lore raw

PATCH 1/1 ocfs2: clean up an unuseful goto in ocfs2_put_slot function

Hi Guozhonghua,
You should follow the rules when submitting patches. Please refer Documentation\SubmittingPatches for details.

Thanks,
Joseph

Quoted 36 lines · Guozhonghua

The goto is not useful in the function ocfs2_put_slot, so delete it.

slot_map.c 2016-04-07 16:53:25.540793954 +0800 renamed from slot_map.c 2016-03-25 15:29:22.175343770 +0800 +2 -6
@@ -535,12 +535,9 @@ void ocfs2_put_slot(struct ocfs2_super *
        spin_unlock(&osb->osb_lock);
 
        status = ocfs2_update_disk_slot(osb, si, slot_num);
-       if (status < 0) {
+       if (status < 0)
                mlog_errno(status);
-               goto bail;
-       }
-
-bail:
+
        ocfs2_free_slot_info(osb);
 }
-------------------------------------------------------------------------------------------------------------------------------------

???????????????????????????????????????? ???????????????????????????????????????? ????????????????????????????????????????
???
This e-mail and its attachments contain confidential information from H3C, which is intended only for the person or entity whose address is listed above. Any use of the information contained herein in any way (including, but not limited to, total or partial disclosure, reproduction, or dissemination) by persons other than the intended recipient(s) is prohibited. If you receive this e-mail in error, please notify the sender by phone or email immediately and delete it!
_______________________________________________
Ocfs2-devel mailing list
Ocfs2-devel at oss.oracle.com
https://oss.oracle.com/mailman/listinfo/ocfs2-devel