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