netatalk  4.4.0
Free and Open Source Apple Filing Protocol (AFP) Server
Loading...
Searching...
No Matches
extattrs.c File Reference
#include <errno.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
#include <atalk/adouble.h>
#include <atalk/afp.h>
#include <atalk/ea.h>
#include <atalk/globals.h>
#include <atalk/logger.h>
#include <atalk/netatalk_conf.h>
#include <atalk/util.h>
#include <atalk/vfs.h>
#include "desktop.h"
#include "directory.h"
#include "extattrs.h"
#include "fork.h"
#include "volume.h"

Functions

int afp_listextattr (AFPObj *obj, char *ibuf, size_t ibuflen, char *rbuf, size_t *rbuflen)
static char * to_stringz (char *ibuf, uint16_t len)
int afp_getextattr (AFPObj *obj, char *ibuf, size_t ibuflen, char *rbuf, size_t *rbuflen)
int afp_setextattr (AFPObj *obj, char *ibuf, size_t ibuflen, char *rbuf, size_t *rbuflen)
int afp_remextattr (AFPObj *obj, char *ibuf, size_t ibuflen, char *rbuf, size_t *rbuflen)

Variables

static const char * ea_finderinfo = "com.apple.FinderInfo"
static const char * ea_resourcefork = "com.apple.ResourceFork"

Function Documentation

◆ afp_getextattr()

int afp_getextattr ( AFPObj * obj,
char * ibuf,
size_t ibuflen,
char * rbuf,
size_t * rbuflen )

◆ afp_listextattr()

int afp_listextattr ( AFPObj * obj,
char * ibuf,
size_t ibuflen,
char * rbuf,
size_t * rbuflen )
Note
we're being called twice. Firstly the client only want the size of all EA names, secondly it wants these names. In order to avoid scanning EAs twice we cache them in a static buffer.

◆ afp_remextattr()

int afp_remextattr ( AFPObj * obj,
char * ibuf,
size_t ibuflen,
char * rbuf,
size_t * rbuflen )

◆ afp_setextattr()

int afp_setextattr ( AFPObj * obj,
char * ibuf,
size_t ibuflen,
char * rbuf,
size_t * rbuflen )

◆ to_stringz()

char * to_stringz ( char * ibuf,
uint16_t len )
static

Variable Documentation

◆ ea_finderinfo

const char* ea_finderinfo = "com.apple.FinderInfo"
static

◆ ea_resourcefork

const char* ea_resourcefork = "com.apple.ResourceFork"
static