* SUCH DAMAGE.
*
* from: @(#)pk_output.c 7.10 (Berkeley) 5/29/91
- * $Id$
+ * $Id: pk_output.c,v 1.3 1993/11/25 01:34:30 wollman Exp $
*/
#include "param.h"
#include "pk_var.h"
struct mbuf_cache pk_output_cache = {0 };
-struct mbuf *nextpk ();
+static struct mbuf *nextpk (struct pklcd *);
-pk_output (lcp)
-register struct pklcd *lcp;
+/*
+ * The `n' argument is just there to make if_x25subr.c happy. We
+ * don't actually do anything with it, although meybe we should.
+ * All the other code passes in a null pointer.
+ */
+int
+pk_output (lcp, n)
+ register struct pklcd *lcp;
+ struct mbuf *n;
{
register struct x25_packet *xp;
register struct mbuf *m;
if (lcp == 0 || pkp == 0) {
printf ("pk_output: zero arg\n");
- return;
+ return -1;
}
while ((m = nextpk (lcp)) != NULL) {
default:
m_freem (m);
- return;
+ return 0;
}
/* Trace the packet. */
mbuf_cache(&pk_output_cache, m);
(*pkp -> pk_lloutput) (pkp -> pk_llnext, m);
}
+ return 0;
}
/*
* packet is composed of one or more mbufs.
*/
-struct mbuf *
+static struct mbuf *
nextpk (lcp)
-struct pklcd *lcp;
+ struct pklcd *lcp;
{
register struct mbuf *m, *n;
struct socket *so = lcp -> lcd_so;