Bug 178472 - [ip6] [patch] make return code consistent with IPv4 code
Summary: [ip6] [patch] make return code consistent with IPv4 code
Status: Closed FIXED
Alias: None
Product: Base System
Classification: Unclassified
Component: kern (show other bugs)
Version: Unspecified
Hardware: Any Any
: Normal Affects Only Me
Assignee: freebsd-net (Nobody)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-05-10 07:10 UTC by Sven-Thorsten Dietrich
Modified: 2014-02-10 14:40 UTC (History)
0 users

See Also:


Attachments
file.diff (377 bytes, patch)
2013-05-10 07:10 UTC, Sven-Thorsten Dietrich
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Sven-Thorsten Dietrich 2013-05-10 07:10:00 UTC
IPv4 code returns EPERM if mrouter not initialized. Make IPv6 do the same.

Fix: Patch attached with submission follows:
Comment 1 Mark Linimon freebsd_committer freebsd_triage 2013-05-10 13:09:35 UTC
Responsible Changed
From-To: freebsd-bugs->freebsd-net

Over to maintainer(s).
Comment 2 dfilter service freebsd_committer freebsd_triage 2014-02-10 14:37:04 UTC
Author: brueffer
Date: Mon Feb 10 14:36:51 2014
New Revision: 261709
URL: http://svnweb.freebsd.org/changeset/base/261709

Log:
  For IPv6, return the same error code as IPv4 when mrouter is not initialized.
  
  PR:		178472
  Submitted by:	Sven-Thorsten Dietrich <sven at vyatta.com>
  Reviewed by:	bms

Modified:
  head/sys/netinet6/ip6_mroute.c

Modified: head/sys/netinet6/ip6_mroute.c
==============================================================================
--- head/sys/netinet6/ip6_mroute.c	Mon Feb 10 12:52:33 2014	(r261708)
+++ head/sys/netinet6/ip6_mroute.c	Mon Feb 10 14:36:51 2014	(r261709)
@@ -361,7 +361,7 @@ X_ip6_mrouter_set(struct socket *so, str
 	mifi_t mifi;
 
 	if (so != V_ip6_mrouter && sopt->sopt_name != MRT6_INIT)
-		return (EACCES);
+		return (EPERM);
 
 	switch (sopt->sopt_name) {
 	case MRT6_INIT:
_______________________________________________
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscribe@freebsd.org"
Comment 3 Christian Brueffer freebsd_committer freebsd_triage 2014-02-10 14:37:05 UTC
State Changed
From-To: open->closed

Committed, thanks!