unsigned long cpu_flags;  sctp_spin_lock_irqsave(&sk->sk_receive_queue.lock, cpu_flags); 
spin_lock_bh(&sk->sk_receive_queue.lock); 
static struct sk_buff *sctp_skb_recv_datagram(struct sock *sk, int flags,					      int noblock, int *err){	int error;	struct sk_buff *skb;	long timeo;	/* Caller is allowed not to check sk->sk_err before calling.  */	error = sock_error(sk);	if (error)		goto no_packet;	timeo = sock_rcvtimeo(sk, noblock);	SCTP_DEBUG_PRINTK("Timeout: timeo: %ld, MAX: %ld.\n",			  timeo, MAX_SCHEDULE_TIMEOUT);	do {		/* Again only user level code calls this function,		 * so nothing interrupt level		 * will suddenly eat the receive_queue.		 *		 *  Look at current nfs client by the way...		 *  However, this function was corrent in any case. 8)		 */		if (flags & MSG_PEEK) {			unsigned long cpu_flags;			sctp_spin_lock_irqsave(&sk->sk_receive_queue.lock,					       cpu_flags);			skb = skb_peek(&sk->sk_receive_queue);			if (skb)				atomic_inc(&skb->users);			sctp_spin_unlock_irqrestore(&sk->sk_receive_queue.lock,						    cpu_flags);		} else {			skb = skb_dequeue(&sk->sk_receive_queue);		}		if (skb)			return skb;		if (sk->sk_shutdown & RCV_SHUTDOWN)			break;		/* User doesn't want to wait.  */		error = -EAGAIN;		if (!timeo)			goto no_packet;	} while (sctp_wait_for_packet(sk, err, &timeo) == 0);	return NULL;no_packet:	*err = error;	return NULL;}
4520	/local/tlutelli/issta_data/temp/c/2005_temp/2005/4520/1e061ab2e5aa50a84d68ca654773632f9c425bb6/socket.c/buggy/net/sctp/socket.c