/***
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 "sd-netlink.h"
#include "ether-addr-util.h"
#include "macro.h"
#include "missing.h"
#include "netlink-util.h"
#include "socket-util.h"
#include "string-util.h"
#include "util.h"
}
const char *name_out;
/* we'd really like to test NEWLINK, but let's not mess with the running kernel */
}
const char *str_data;
assert_se(m);
/* u8 test cases */
/* u32 test cases */
}
const char *label;
assert_se(m);
}
static void test_route(void) {
int r;
if (r < 0) {
log_error_errno(r, "Could not create RTM_NEWROUTE message: %m");
return;
}
if (r < 0) {
log_error_errno(r, "Could not append RTA_GATEWAY attribute: %m");
return;
}
if (r < 0) {
log_error_errno(r, "Could not append RTA_OIF attribute: %m");
return;
}
}
static void test_multiple(void) {
}
const char *data;
assert_se(m);
return 1;
}
char *ifname;
}
int r;
(*counter) --;
r = sd_netlink_message_get_errno(m);
assert_se(r >= 0);
return 1;
}
char *ifname;
}
int counter = 0;
counter ++;
counter ++;
while (counter > 0) {
}
}
static void test_container(void) {
const char *string_data;
assert_se(sd_netlink_message_close_container(m) >= 0);
assert_se(sd_netlink_message_close_container(m) >= 0);
assert_se(sd_netlink_message_rewind(m) >= 0);
assert_se(sd_netlink_message_exit_container(m) >= 0);
assert_se(sd_netlink_message_exit_container(m) >= 0);
}
static void test_match(void) {
}
for (m = reply; m; m = sd_netlink_message_next(m)) {
}
}
static void test_message(void) {
}
int main(void) {
const char *string_data;
int if_loopback;
test_message();
test_match();
test_route();
assert_se(if_loopback > 0);
assert_se(m);
return EXIT_SUCCESS;
}