libvirt's network config documents that a bridge's STP "forward delay"
(called "delay" in the XML) should be specified in seconds, but
virNetDevBridgeSetSTPDelay() assumes that it is given a delay in
milliseconds (although the comment at the top of the function
incorrectly says "seconds".
This fixes the comment, and converts the delay to milliseconds before
calling virNetDevBridgeSetSTPDelay().
}
/* Set bridge options */
+
+ /* delay is configured in seconds, but virNetDevBridgeSetSTPDelay
+ * expects milliseconds
+ */
if (virNetDevBridgeSetSTPDelay(network->def->bridge,
- network->def->delay) < 0)
+ network->def->delay * 1000) < 0)
goto err1;
if (virNetDevBridgeSetSTP(network->def->bridge,
/*
- * Copyright (C) 2007-2011 Red Hat, Inc.
+ * Copyright (C) 2007-2012 Red Hat, Inc.
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
/**
* virNetDevBridgeSetSTPDelay:
* @brname: the bridge name
- * @delay: delay in seconds
+ * @delay: delay in milliseconds
*
* Set the bridge forward delay
*