Index: ossp-pkg/l2/l2_ch_file.c RCS File: /v/ossp/cvs/ossp-pkg/l2/l2_ch_file.c,v rcsdiff -q -kk '-r1.22' '-r1.23' -u '/v/ossp/cvs/ossp-pkg/l2/l2_ch_file.c,v' 2>/dev/null --- l2_ch_file.c 2002/03/13 14:49:39 1.22 +++ l2_ch_file.c 2002/07/29 17:42:25 1.23 @@ -86,6 +86,7 @@ { l2_ch_file_t *cfg = (l2_ch_file_t *)ctx->vp; int mode; + mode_t mask; /* make sure a path was set */ if (cfg->path == NULL) @@ -97,7 +98,10 @@ mode |= O_APPEND; else mode |= O_TRUNC; - if ((cfg->fd = open(cfg->path, mode, cfg->perm)) == -1) + mask = umask(0); + cfg->fd = open(cfg->path, mode, cfg->perm); + umask(mask); + if (cfg->fd == -1) return L2_ERR_SYS; return L2_OK; Index: ossp-pkg/l2/l2_ut_param.c RCS File: /v/ossp/cvs/ossp-pkg/l2/l2_ut_param.c,v rcsdiff -q -kk '-r1.7' '-r1.8' -u '/v/ossp/cvs/ossp-pkg/l2/l2_ut_param.c,v' 2>/dev/null --- l2_ut_param.c 2002/01/02 17:07:38 1.7 +++ l2_ut_param.c 2002/07/29 17:42:25 1.8 @@ -126,7 +126,13 @@ switch (pa[i].type) { case L2_TYPE_INT: { /* integer parameter */ - long val = strtol(cpB, &cpE, 10); + long val; + if (strlen(cpB) > 2 && cpB[0] == '0' && cpB[1] == 'x') + val = strtol(cpB+2, &cpE, 16); + else if (strlen(cpB) > 1 && cpB[0] == '0') + val = strtol(cpB+1, &cpE, 8); + else + val = strtol(cpB, &cpE, 10); if ((val == LONG_MIN || val == LONG_MAX) && errno == ERANGE) { l2_env_errorinfo(env, L2_ERR_ARG, "numerical parameter value out of range "