Style fixes.

Style fixes pointed out by Axel. I'm rusty, and it shows.
Hope I got it right.
Also moved get_route() into BPrivate.
This commit is contained in:
Stefano Ceccherini 2013-11-18 19:53:39 +01:00
parent fc51be0a4e
commit 0bc615438a
4 changed files with 19 additions and 3 deletions

View File

@ -2,13 +2,21 @@
* Copyright 2013, Haiku, Inc. All Rights Reserved.
* Distributed under the terms of the MIT License.
*/
#ifndef ROUTESUPPORT_H_
#define ROUTESUPPORT_H_
#include <ObjectList.h>
namespace BPrivate {
status_t get_routes(const char* interfaceName,
int family, BObjectList<route_entry>& routes);
}
#endif /* __ROUTESUPPORT_H_ */

View File

@ -569,7 +569,7 @@ BNetworkInterface::RemoveDefaultRoute(int family)
status_t
BNetworkInterface::GetRoutes(int family, BObjectList<route_entry>& routes) const
{
return get_routes(Name(), family, routes);
return BPrivate::get_routes(Name(), family, routes);
}

View File

@ -166,7 +166,7 @@ BNetworkRoster::RemoveInterface(const BNetworkInterface& interface)
status_t
BNetworkRoster::GetRoutes(int family, BObjectList<route_entry>& routes) const
{
return get_routes(NULL, family, routes);
return BPrivate::get_routes(NULL, family, routes);
}

View File

@ -3,6 +3,7 @@
* Distributed under the terms of the MIT License.
*/
#include <errno.h>
#include <net/if.h>
#include <sys/sockio.h>
@ -11,6 +12,10 @@
#include <ObjectList.h>
#include <RouteSupport.h>
namespace BPrivate {
status_t
get_routes(const char* interfaceName, int family, BObjectList<route_entry>& routes)
{
@ -72,3 +77,6 @@ get_routes(const char* interfaceName, int family, BObjectList<route_entry>& rout
return B_OK;
}
}