Commit 977fc93
committed
flexfiles/pNFS: fix NULL checks on result of ff_layout_choose_ds_for_read
JIRA: https://issues.redhat.com/browse/RHEL-110294
commit 5a46d23
Author: Tigran Mkrtchyan <tigran.mkrtchyan@desy.de>
Date: Thu Aug 28 16:51:00 2025 +0200
flexfiles/pNFS: fix NULL checks on result of ff_layout_choose_ds_for_read
Recent commit f06bedf ("pNFS/flexfiles: don't attempt pnfs on fatal DS
errors") has changed the error return type of ff_layout_choose_ds_for_read() from
NULL to an error pointer. However, not all code paths have been updated
to match the change. Thus, some non-NULL checks will accept error pointers
as a valid return value.
Reported-by: Dan Carpenter <dan.carpenter@linaro.org>
Suggested-by: Dan Carpenter <dan.carpenter@linaro.org>
Fixes: f06bedf ("pNFS/flexfiles: don't attempt pnfs on fatal DS errors")
Signed-off-by: Tigran Mkrtchyan <tigran.mkrtchyan@desy.de>
Signed-off-by: Trond Myklebust <trond.myklebust@hammerspace.com>
Signed-off-by: Benjamin Coddington <bcodding@redhat.com>1 parent 0e347be commit 977fc93
1 file changed
+12
-7
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
773 | 773 | | |
774 | 774 | | |
775 | 775 | | |
776 | | - | |
| 776 | + | |
| 777 | + | |
| 778 | + | |
777 | 779 | | |
| 780 | + | |
778 | 781 | | |
779 | 782 | | |
780 | 783 | | |
| |||
804 | 807 | | |
805 | 808 | | |
806 | 809 | | |
807 | | - | |
| 810 | + | |
808 | 811 | | |
809 | 812 | | |
810 | 813 | | |
| |||
818 | 821 | | |
819 | 822 | | |
820 | 823 | | |
821 | | - | |
| 824 | + | |
822 | 825 | | |
823 | 826 | | |
824 | 827 | | |
| |||
868 | 871 | | |
869 | 872 | | |
870 | 873 | | |
871 | | - | |
| 874 | + | |
872 | 875 | | |
873 | 876 | | |
874 | 877 | | |
| |||
1072 | 1075 | | |
1073 | 1076 | | |
1074 | 1077 | | |
| 1078 | + | |
1075 | 1079 | | |
1076 | | - | |
1077 | | - | |
1078 | | - | |
| 1080 | + | |
| 1081 | + | |
1079 | 1082 | | |
| 1083 | + | |
| 1084 | + | |
1080 | 1085 | | |
1081 | 1086 | | |
1082 | 1087 | | |
| |||
0 commit comments