aboutsummaryrefslogtreecommitdiff
path: root/nis/nss_nisplus/nisplus-proto.c
diff options
context:
space:
mode:
Diffstat (limited to 'nis/nss_nisplus/nisplus-proto.c')
-rw-r--r--nis/nss_nisplus/nisplus-proto.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/nis/nss_nisplus/nisplus-proto.c b/nis/nss_nisplus/nisplus-proto.c
index b26cb8230e..5cb55d367c 100644
--- a/nis/nss_nisplus/nisplus-proto.c
+++ b/nis/nss_nisplus/nisplus-proto.c
@@ -60,14 +60,14 @@ _nss_nisplus_parse_protoent (nis_result * result, struct protoent *proto,
struct parser_data *data = (void *) buffer;
if (result == NULL)
- return -1;
+ return 0;
if ((result->status != NIS_SUCCESS && result->status != NIS_S_SUCCESS) ||
result->objects.objects_val[0].zo_data.zo_type != ENTRY_OBJ ||
strcmp (result->objects.objects_val[0].zo_data.objdata_u.en_data.en_type,
"protocols_tbl") != 0 ||
result->objects.objects_val[0].zo_data.objdata_u.en_data.en_cols.en_cols_len < 3)
- return -1;
+ return 0;
memset (p, '\0', room_left);
@@ -75,7 +75,7 @@ _nss_nisplus_parse_protoent (nis_result * result, struct protoent *proto,
if (NISENTRYLEN (0, 0, result) + 1 > room_left)
{
__set_errno (ERANGE);
- return -1;
+ return 0;
}
strncpy (p, NISENTRYVAL (0, 0, result), NISENTRYLEN (0, 0, result));
room_left -= (NISENTRYLEN (0, 0, result) + 1);
@@ -83,7 +83,7 @@ _nss_nisplus_parse_protoent (nis_result * result, struct protoent *proto,
if (NISENTRYLEN (0, 2, result) + 1 > room_left)
{
__set_errno (ERANGE);
- return -1;
+ return 0;
}
strcat (p, "\t");
strncat (p, NISENTRYVAL (0, 2, result), NISENTRYLEN (0, 2, result));
@@ -95,7 +95,7 @@ _nss_nisplus_parse_protoent (nis_result * result, struct protoent *proto,
if (NISENTRYLEN (i, 1, result) + 1 > room_left)
{
__set_errno (ERANGE);
- return -1;
+ return 0;
}
strcat (p, " ");
strncat (p, NISENTRYVAL (i, 1, result), NISENTRYLEN (i, 1, result));