70 struct uri *resolved_uri;
75 if ( ! resolved_uri ) {
84 "unsupported URI scheme \"%s\"\n",
93 if ( (
rc = opener->
open ( intf, resolved_uri ) ) != 0 ) {
117 const char *uri_string ) {
153 return opener->
open ( intf,
peer, local );
157 "unsupported socket type (%s,%s)\n",
174 const char *uri_string =
va_arg ( args,
const char * );
182 int semantics =
va_arg ( args,
int );
189 "open unsupported location type %d\n",
#define NULL
NULL pointer (VOID *)
struct arbelprm_rc_send_wqe rc
struct uri * cwuri
Current working URI.
uint32_t type
Operating system type.
#define FILE_LICENCE(_licence)
Declare a particular licence as applying to a file.
#define ENOMEM
Not enough space.
#define ENOTSUP
Operation not supported.
#define FILE_SECBOOT(_status)
Declare a file's UEFI Secure Boot permission status.
void intf_restart(struct interface *intf, int rc)
Shut down and restart an object interface.
#define INTF_DBG(intf)
printf() arguments for representing an object interface
#define INTF_COL(intf)
Find debugging colourisation for an object interface.
#define INTF_FMT
printf() format string for INTF_DBG()
struct mschapv2_challenge peer
Peer challenge.
int xfer_vreopen(struct interface *intf, int type, va_list args)
Reopen location.
int xfer_open_socket(struct interface *intf, int semantics, struct sockaddr *peer, struct sockaddr *local)
Open socket.
int xfer_open_uri(struct interface *intf, struct uri *uri)
Open URI.
int xfer_open(struct interface *intf, int type,...)
Open location.
int xfer_vopen(struct interface *intf, int type, va_list args)
Open location.
struct uri_opener * xfer_uri_opener(const char *scheme)
Find opener for URI scheme.
int xfer_open_uri_string(struct interface *intf, const char *uri_string)
Open URI string.
Data transfer interface opening.
#define SOCKET_OPENERS
Socket opener table.
@ LOCATION_SOCKET
Location is a socket.
@ LOCATION_URI
Location is a URI.
@ LOCATION_URI_STRING
Location is a URI string.
#define URI_OPENERS
URI opener table.
static const char * socket_semantics_name(int semantics)
Name communication semantics.
static const char * socket_family_name(int family)
Name address family.
#define va_start(ap, last)
__builtin_va_list va_list
char * strerror(int errno)
Retrieve string representation of error number.
int strcasecmp(const char *first, const char *second)
Compare case-insensitive strings.
Generalized socket address structure.
int(* open)(struct interface *intf, struct sockaddr *peer, struct sockaddr *local)
Open socket.
int semantics
Communication semantics (e.g.
const char * scheme
URI protocol name.
int(* open)(struct interface *intf, struct uri *uri)
Open URI.
A Uniform Resource Identifier.
const char * scheme
Scheme.
#define for_each_table_entry(pointer, table)
Iterate through all entries within a linker table.
struct uri * parse_uri(const char *uri_string)
Parse URI.
struct uri * resolve_uri(const struct uri *base_uri, struct uri *relative_uri)
Resolve base+relative URI.
Uniform Resource Identifiers.
static void uri_put(struct uri *uri)
Decrement URI reference count.
Data transfer interfaces.