5 int zpm_quote(char *value, char *dest, size_t n) {
10 /* figure out length of quoted string */
11 for (s = value; *s; s++) {
13 if (*s == '\'') dlen++;
16 /* if there's enough room for the string and the terminating null
17 * byte, quote the string
19 if (dest && dlen < n) {
31 /* returns either the number of characters written or would