]> git.proxmox.com Git - mirror_frr.git/blobdiff - lib/network.h
zebra, lib: fix the ZEBRA_INTERFACE_VRF_UPDATE zapi message
[mirror_frr.git] / lib / network.h
index 0fcb575d1cea7af6d2ef8d21dfa4f33e8d87bb01..4703dc9b6364635494d8aa9f7a07d20348a67147 100644 (file)
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
  * General Public License for more details.
  *
- * You should have received a copy of the GNU General Public License
- * along with GNU Zebra; see the file COPYING.  If not, write to the Free
- * Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
- * 02111-1307, USA.  
+ * You should have received a copy of the GNU General Public License along
+ * with this program; see the file COPYING; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
  */
 
 #ifndef _ZEBRA_NETWORK_H
 /* Both readn and writen are deprecated and will be removed.  They are not
    suitable for use with non-blocking file descriptors.
  */
-extern int readn (int, u_char *, int);
-extern int writen (int, const u_char *, int);
+extern int readn(int, uint8_t *, int);
+extern int writen(int, const uint8_t *, int);
 
 /* Set the file descriptor to use non-blocking I/O.  Returns 0 for success,
    -1 on error. */
 extern int set_nonblocking(int fd);
 
+extern int set_cloexec(int fd);
+
 /* Does the I/O error indicate that the operation should be retried later? */
-#define ERRNO_IO_RETRY(EN) \
+#define ERRNO_IO_RETRY(EN)                                                     \
        (((EN) == EAGAIN) || ((EN) == EWOULDBLOCK) || ((EN) == EINTR))
 
-extern float htonf (float);
-extern float ntohf (float);
+extern float htonf(float);
+extern float ntohf(float);
 
 #endif /* _ZEBRA_NETWORK_H */