All checks were successful
Source release / source-package (push) Successful in 48s
Wire NCP 0x23/0x0c AFP Get Entry ID From Path Name to a real path lookup when the optional Netatalk/libatalk backend is available. The WebSDK documents NCP 0x2222/35/12 as converting a NetWare directory handle plus short-name path string into a unique 32-bit Macintosh file or directory Entry ID. The request carries the AFP subfunction, NetWare directory handle, path length, and path string; the reply carries the 4-byte AFP Entry ID. The SDK headers expose the same operation as AFPGetEntryIDFromPathName() and NWAFPGetEntryIDFromPathName(), and NWAFPSupported() uses this path-name probe to test AFP support. Resolve the NetWare directory handle and path through the existing mars_nwe path machinery, require the optional libatalk backend before returning AFP success, and then ask libatalk for an AppleDouble/CNID-style id when available. If libatalk is present but the file has no stored id yet, return a deterministic stat-derived local entry id as a temporary fallback so the path-name probe can succeed without inventing NetWare directory base numbers. Keep all other AFP subfunctions returning invalid namespace for now. They still need Finder Info, resource fork, AFP file information, fork open, and persistent CNID/directory-id support before they can safely report success. Add the SDK request/reply semantics to the inline endpoint comments and keep the remaining AFP work tracked in TODO.md. This implements only the AFP path-to-entry-id probe; it does not add general AFP file or resource-fork semantics yet.
15 lines
395 B
C
15 lines
395 B
C
#ifndef _NWATALK_H_
|
|
#define _NWATALK_H_
|
|
|
|
#include "net.h"
|
|
|
|
#define NWATALK_FINDER_INFO_LEN 32
|
|
|
|
int nwatalk_backend_available(void);
|
|
int nwatalk_get_finder_info(const char *path, uint8 *finder_info,
|
|
int finder_info_len);
|
|
int nwatalk_get_resource_fork_size(const char *path, uint32 *resource_size);
|
|
int nwatalk_get_entry_id(const char *path, uint32 *entry_id);
|
|
|
|
#endif
|