Skip to content

Commit

Permalink
Update regex; fix to io.c; update de.po, fi.po.
Browse files Browse the repository at this point in the history
  • Loading branch information
arnoldrobbins committed May 18, 2011
1 parent ad61e1c commit 7745904
Show file tree
Hide file tree
Showing 11 changed files with 1,188 additions and 1,329 deletions.
7 changes: 7 additions & 0 deletions ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,10 @@
Wed May 18 21:47:54 2011 Arnold D. Robbins <arnold@skeeve.com>

* io.c (PIPES_SIMULATED): Simplify the case where PIPES_SIMULATED
is true but using temporary files - that code not needed anymore.
* regcomp.c, regex.h, regex_internal.c, regex_internal.h,
regexec.c: Sync with GLIBC. Why not.

Mon May 16 17:55:25 2011 Arnold D. Robbins <arnold@skeeve.com>

* awkgram.c: Regenerated using bison 2.5.
Expand Down
1 change: 0 additions & 1 deletion TODO
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
Sync regex.h to glibc
Add debugger commands to reference card
Review all FIXME and TODO comments

Expand Down
57 changes: 0 additions & 57 deletions io.c
Original file line number Diff line number Diff line change
Expand Up @@ -2122,8 +2122,6 @@ gawk_pclose(struct redirect *rp)
* except if popen() provides real pipes too
*/

#if defined(__DJGPP__) || defined(__MINGW32__) || defined(VMS) || defined(__EMX__)

/* gawk_popen --- open an IOBUF on a child process */

static IOBUF *
Expand Down Expand Up @@ -2163,61 +2161,6 @@ gawk_pclose(struct redirect *rp)
rp->ifp = NULL;
return (rval < 0 ? rval : aval);
}
#else /* not (__DJGPP__ || __MINGW32__ || VMS || __EMX__) */

static struct pipeinfo {
char *command;
char *name;
} pipes[_NFILE];

/* gawk_popen --- open an IOBUF on a child process */

static IOBUF *
gawk_popen(const char *cmd, struct redirect *rp)
{
int current;
char *name;
static char cmdbuf[256];

/* get a name to use */
if ((name = tempnam(".", "pip")) == NULL)
return NULL;
sprintf(cmdbuf, "%s > %s", cmd, name);
system(cmdbuf);
if ((current = open(name, O_RDONLY)) == INVALID_HANDLE)
return NULL;
pipes[current].name = name;
emalloc(pipes[current].command, char *, strlen(cmd)+1, "gawk_popen");
strcpy(pipes[current].command, cmd);
os_close_on_exec(current, cmd, "pipe", "from");
rp->iop = iop_alloc(current, name, NULL, TRUE);
if (rp->iop == NULL)
(void) close(current);
return rp->iop;
}

/* gawk_pclose --- close an open child pipe */

static int
gawk_pclose(struct redirect *rp)
{
int cur = rp->iop->fd;
int rval = 0;

if (rp->iop != NULL)
rval = iop_close(rp->iop);
rp->iop = NULL;

/* check for an open file */
if (pipes[cur].name == NULL)
return -1;
unlink(pipes[cur].name);
efree(pipes[cur].name);
pipes[cur].name = NULL;
efree(pipes[cur].command);
return rval;
}
#endif /* not (__DJGPP__ || __MINGW32__ || VMS || __EMX__) */

#endif /* PIPES_SIMULATED */

Expand Down
4 changes: 4 additions & 0 deletions po/ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
Wed May 18 21:45:31 2011 Arnold D. Robbins <arnold@skeeve.com>

* LINGUAS: Updated and sorted.

Sun May 1 20:32:10 2011 Arnold D. Robbins <arnold@skeeve.com>

* LINGUAS: Removed all files not updated recently; some have been
Expand Down
Loading

0 comments on commit 7745904

Please sign in to comment.