networkd-network.c revision 7384fa923e1ba403454903133b33f559b735fe75
/*-*- Mode: C; c-basic-offset: 8; indent-tabs-mode: nil -*-*/
/***
This file is part of systemd.
Copyright 2013 Tom Gundersen <teg@jklm.no>
under the terms of the GNU Lesser General Public License as published by
the Free Software Foundation; either version 2.1 of the License, or
(at your option) any later version.
systemd is distributed in the hope that it will be useful, but
WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Lesser General Public License for more details.
You should have received a copy of the GNU Lesser General Public License
along with systemd; If not, see <http://www.gnu.org/licenses/>.
***/
#include "networkd.h"
#include "net-util.h"
#include "path-util.h"
#include "conf-files.h"
#include "conf-parser.h"
int r;
if (!file) {
return 0;
else
return errno;
}
if (!network)
return log_oom();
if (!network->addresses_by_section)
return log_oom();
if (!network->routes_by_section)
return log_oom();
return log_oom();
(void*) network_gperf_lookup, false, false, network);
if (r < 0) {
return r;
}
return 0;
}
char **files, **f;
int r;
if (r < 0) {
return r;
}
STRV_FOREACH_BACKWARDS(f, files) {
r = network_load_one(manager, *f);
if (r < 0)
return r;
}
return 0;
}
if (!network)
return;
}
if (manager_should_reload(manager))
log_debug("%s: found matching network '%s'",
return 0;
}
}
return -ENOENT;
}
int r;
r = link_configure(link);
if (r < 0)
return r;
return 0;
}
int config_parse_bridge(const char *unit,
const char *filename,
unsigned line,
const char *section,
unsigned section_line,
const char *lvalue,
int ltype,
const char *rvalue,
void *data,
void *userdata) {
int r;
if (r < 0) {
"Bridge is invalid, ignoring assignment: %s", rvalue);
return 0;
}
return 0;
}