tools/adflib: build only host variant which is used by Sam440 target
[AROS.git] / rom / exec / findport.c
blobcae2512db0e3e1c31e9befe9dff48624e4d4809f
1 /*
2 Copyright © 1995-2001, The AROS Development Team. All rights reserved.
3 $Id$
5 Desc: Search for a port by name.
6 Lang: english
7 */
8 #include <exec/execbase.h>
9 #include <aros/libcall.h>
10 #include <proto/exec.h>
12 /*****************************************************************************
14 NAME */
16 AROS_LH1(struct MsgPort *, FindPort,
18 /* SYNOPSIS */
19 AROS_LHA(CONST_STRPTR, name, A1),
21 /* LOCATION */
22 struct ExecBase *, SysBase, 65, Exec)
24 /* FUNCTION
25 Look for a public messageport by name. This function doesn't
26 arbitrate for the port list and must be protected with a Forbid()
27 Permit() pair.
29 INPUTS
30 port - Pointer to NUL terminated C string.
32 RESULT
33 Pointer to struct MsgPort or NULL if there is no port of that name.
35 NOTES
37 EXAMPLE
39 BUGS
41 SEE ALSO
43 INTERNALS
45 ******************************************************************************/
47 AROS_LIBFUNC_INIT
49 /* Nothing spectacular - just look for that name. */
50 return (struct MsgPort *)FindName(&SysBase->PortList,name);
51 AROS_LIBFUNC_EXIT
52 } /* FindPort */