/[hurd]/hurd/libpager/demuxer.c
ViewVC logotype

Diff of /hurd/libpager/demuxer.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.8 by mib, Tue Jun 20 16:56:05 1995 UTC revision 1.9 by marcus, Fri Jan 18 15:37:22 2002 UTC
# Line 1  Line 1 
1  /* Demuxer for pager library  /* Demuxer for pager library
2     Copyright (C) 1994, 1995 Free Software Foundation     Copyright (C) 1994, 1995, 2002 Free Software Foundation
3    
4     This program is free software; you can redistribute it and/or     This program is free software; you can redistribute it and/or
5     modify it under the terms of the GNU General Public License as     modify it under the terms of the GNU General Public License as
# Line 20  Line 20 
20  #include "notify_S.h"  #include "notify_S.h"
21    
22  /* Demultiplex a single message directed at a pager port; INP is the  /* Demultiplex a single message directed at a pager port; INP is the
23     message received; fille OUTP with the reply.  */     message received; fill OUTP with the reply.  */
24  int  int
25  pager_demuxer (mach_msg_header_t *inp,  pager_demuxer (mach_msg_header_t *inp,
26                 mach_msg_header_t *outp)                 mach_msg_header_t *outp)
# Line 30  pager_demuxer (mach_msg_header_t *inp, Line 30  pager_demuxer (mach_msg_header_t *inp,
30    extern int _pager_seqnos_notify_server (mach_msg_header_t *inp,    extern int _pager_seqnos_notify_server (mach_msg_header_t *inp,
31                                            mach_msg_header_t *outp);                                            mach_msg_header_t *outp);
32        
33    return (_pager_seqnos_memory_object_server (inp, outp)    int result = _pager_seqnos_memory_object_server (inp, outp)
34            || _pager_seqnos_notify_server (inp, outp));      || _pager_seqnos_notify_server (inp, outp);
35      if (!result)
36        {
37          struct pager *p;
38    
39          p = ports_lookup_port (0, inp->msgh_remote_port, _pager_class);
40          if (p)
41            {
42              mutex_lock (&p->interlock);
43              _pager_wait_for_seqno (p, seqno);
44              _pager_release_seqno (p, seqno);
45              mutex_unlock (&p->interlock);
46              ports_port_deref (p);
47            }
48        }
49      return result;
50  }  }
51    
52    
53    

Legend:
Removed from v.1.8  
changed lines
  Added in v.1.9

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26