if_tap.c (162711) | if_tap.c (163915) |
---|---|
1/*- 2 * Copyright (C) 1999-2000 by Maksim Yevmenkin <m_evmenkin@yahoo.com> 3 * All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 17 unchanged lines hidden (view full) --- 26 * BASED ON: 27 * ------------------------------------------------------------------------- 28 * 29 * Copyright (c) 1988, Julian Onions <jpo@cs.nott.ac.uk> 30 * Nottingham University 1987. 31 */ 32 33/* | 1/*- 2 * Copyright (C) 1999-2000 by Maksim Yevmenkin <m_evmenkin@yahoo.com> 3 * All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 17 unchanged lines hidden (view full) --- 26 * BASED ON: 27 * ------------------------------------------------------------------------- 28 * 29 * Copyright (c) 1988, Julian Onions <jpo@cs.nott.ac.uk> 30 * Nottingham University 1987. 31 */ 32 33/* |
34 * $FreeBSD: head/sys/net/if_tap.c 162711 2006-09-27 19:57:02Z ru $ | 34 * $FreeBSD: head/sys/net/if_tap.c 163915 2006-11-02 17:37:22Z andre $ |
35 * $Id: if_tap.c,v 0.21 2000/07/23 21:46:02 max Exp $ 36 */ 37 38#include "opt_compat.h" 39#include "opt_inet.h" 40 41#include <sys/param.h> 42#include <sys/conf.h> --- 779 unchanged lines hidden (view full) --- 822 823 if ((uio->uio_resid < 0) || (uio->uio_resid > TAPMRU)) { 824 TAPDEBUG("%s invalid packet len = %d, minor = %#x\n", 825 ifp->if_xname, uio->uio_resid, minor(dev)); 826 827 return (EIO); 828 } 829 | 35 * $Id: if_tap.c,v 0.21 2000/07/23 21:46:02 max Exp $ 36 */ 37 38#include "opt_compat.h" 39#include "opt_inet.h" 40 41#include <sys/param.h> 42#include <sys/conf.h> --- 779 unchanged lines hidden (view full) --- 822 823 if ((uio->uio_resid < 0) || (uio->uio_resid > TAPMRU)) { 824 TAPDEBUG("%s invalid packet len = %d, minor = %#x\n", 825 ifp->if_xname, uio->uio_resid, minor(dev)); 826 827 return (EIO); 828 } 829 |
830 if ((m = m_uiotombuf(uio, M_DONTWAIT, 0, ETHER_ALIGN)) == NULL) { | 830 if ((m = m_uiotombuf(uio, M_DONTWAIT, 0, ETHER_ALIGN, 831 M_PKTHDR)) == NULL) { |
831 ifp->if_ierrors ++; 832 return (error); 833 } 834 835 m->m_pkthdr.rcvif = ifp; 836 837 /* Pass packet up to parent. */ 838 (*ifp->if_input)(ifp, m); --- 146 unchanged lines hidden --- | 832 ifp->if_ierrors ++; 833 return (error); 834 } 835 836 m->m_pkthdr.rcvif = ifp; 837 838 /* Pass packet up to parent. */ 839 (*ifp->if_input)(ifp, m); --- 146 unchanged lines hidden --- |