dh_installchangelogs: adjust to use ckc301.txt. changelog: explain -O1 usage
[ckermit.git] / ckuus4.c
index 35cfa5f..946603a 100644 (file)
--- a/ckuus4.c
+++ b/ckuus4.c
@@ -1110,7 +1110,9 @@ struct keytab fnctab[] = {              /* Function names */
 #else
     { "permissions",FN_PERM, CM_INV},   /* Permissions of file */
 #endif /* CK_PERMS */
+#ifdef SEEK_CUR
     { "pictureinfo",FN_PICTURE, 0 },   /* Picture orientation/dimensions */
+#endif /* SEEK_CUR */
     { "radix",      FN_RADIX, 0 },     /* Radix conversion */
 #ifndef NORANDOM
     { "random",     FN_RAND, 0},        /* Random number */
@@ -11833,6 +11835,7 @@ fneval(fn,argp,argn,xp) char *fn, *argp[]; int argn; char * xp; {
        goto fnend;
     }
 
+#ifdef SEEK_CUR
 /*
    \fpicture():   Get dimensions of GIF or JPG image.
    fdc June 2006
@@ -11967,6 +11970,8 @@ fneval(fn,argp,argn,xp) char *fn, *argp[]; int argn; char * xp; {
        }
        goto fnend;
     }
+#endif /* SEEK_CUR */
+
     if (cx == FN_PID) {
        int x = -1;
        if (chknum(bp[0])) {            /* Need numeric argument */
@@ -14866,7 +14871,7 @@ zzstring(s,s2,n) char *s; char **s2; int *n; {
                         int i;
                         for (i = 0; i < k-1; i++) {
                             if (vnambuf[i] == '[') {
-                               bprc = boundspair(vnambuf,":_",&x1,&x2,&c);
+                               bprc = boundspair(vnambuf,":_.",&x1,&x2,&c);
                                debug(F111,"zzstring boundspair",vnambuf,bprc);
                                debug(F000,"zzstring boundspair c","",c);
                                if (bprc > -1) {
@@ -14915,18 +14920,22 @@ zzstring(s,s2,n) char *s; char **s2; int *n; {
                                debug(F000,">>> c","",c);
                                 if ((q = malloc(k+1))) {
                                     strcpy(q,vp); /* safe */
+                                   if (c == '.') {
+                                       q[x1+1] = NUL;
+                                       debug(F000,"XXX. q",q,c);
+                                   }
                                    if (c == ':') { /* start:length */
                                        if ((x2 > -1) && ((x1 + x2) <= k)) {
                                            q[x1+x2] = NUL;
                                        }
-                                       debug(F000,"XXX q",q,c);
+                                       debug(F000,"XXX: q",q,c);
                                    } else if (c == '_') { /* start_endpos */
                                        if (x1 >= x2) {
                                            q[x1 = 0] = NUL;
                                        } else if (x2 < k && x2 > -1) {
                                            q[x2] = NUL;
                                        }
-                                       debug(F000,"XXX q",q,c);
+                                       debug(F000,"XXX_ q",q,c);
                                    }
                                    vp = q+x1;
                                 } else vp = NULL;