netatalk: getzones.c File Reference

netatalk 4.5.0
Free and Open Source Apple Filing Protocol (AFP) Server
Loading...
Searching...
No Matches
getzones.c File Reference
`#include <sys/types.h>`
`#include <sys/socket.h>`
`#include <sys/param.h>`
`#include <sys/uio.h>`
`#include <sys/time.h>`
`#include <unistd.h>`
`#include <netdb.h>`
`#include <stdio.h>`
`#include <string.h>`
`#include <stdlib.h>`
`#include <netatalk/at.h>`
`#include <atalk/atp.h>`
`#include <atalk/ddp.h>`
`#include <atalk/netddp.h>`
`#include <atalk/util.h>`
`#include <atalk/unicode.h>`
`#include <atalk/zip.h>`

## Macros
#define | MACCHARSET "MAC_ROMAN"
#define | ZIPOP_DEFAULT ZIPOP_GETZONELIST

## Functions
static void | print_zones (short n, const char *buf, charset_t charset)
| Print zones from a getzone reply.
void | do_atp_lookup (struct sockaddr_at *saddr, uint8_t lookup_type, charset_t charset)
static void | print_gnireply (ssize_t len, uint8_t *buf, charset_t charset)
void | do_getnetinfo (struct sockaddr_at *dest, const char *zone_to_confirm, charset_t charset)
static int | print_and_count_zones_in_reply (uint8_t *buf, size_t len, charset_t charset)
void | do_query (struct sockaddr_at *dest, uint16_t network, charset_t charset)
static void | usage (char *s)
int | main (int argc, char *argv[])

## Macro Definition Documentation

## ◆ MACCHARSET

#define MACCHARSET "MAC_ROMAN"

## ◆ ZIPOP_DEFAULT

#define ZIPOP_DEFAULT ZIPOP_GETZONELIST

## Function Documentation

## ◆ do_atp_lookup()

void do_atp_lookup | ( | struct sockaddr_at * | saddr,
|  | uint8_t | lookup_type,
|  | charset_t | charset )

## ◆ do_getnetinfo()

void do_getnetinfo | ( | struct sockaddr_at * | dest,
|  | const char * | zone_to_confirm,
|  | charset_t | charset )

## ◆ do_query()

void do_query | ( | struct sockaddr_at * | dest,
|  | uint16_t | network,
|  | charset_t | charset )

## ◆ main()

int main | ( | int | argc,
|  | char * | argv[] )

## ◆ print_and_count_zones_in_reply()

int print_and_count_zones_in_reply | ( | uint8_t * | buf,
|  | size_t | len,
|  | charset_t | charset )
| static

## ◆ print_gnireply()

void print_gnireply | ( | ssize_t | len,
|  | uint8_t * | buf,
|  | charset_t | charset )
| static

## ◆ print_zones()

void print_zones | ( | short | n,
|  | const char * | buf,
|  | charset_t | charset )
| static

Print zones from a getzone reply.

Parameters

  n | number of zones in this packet
  buf | zone length/name pairs
  charset | charset to convert zone names from

## ◆ usage()

void usage | ( | char * | s | ) |
| static