EXEC(3) Library Functions Manual EXEC(3)

KS_exec_diffexecution wrappers for common utilities

#include <libks/exec.h>

int
KS_exec_diff(const char *path, const char *src, size_t srclen, const char *dst, size_t dstlen);

The exec API provides execution wrappers for common utilities.

The () function outputs any difference between src and dst using diff(1). Favoring a unified diff using path as the template for the labels.

KS_exec_diff() returns zero if the contents of src and dst are equal. Otherwise, 1 is returned. On failure, -1 is returned and errno is set accordingly.

Anton Lindqvist <anton@basename.se>

OpenBSD 7.8 December 25, 2023 EXEC(3)