Skip to content

Commit

Permalink
cmd/flux-proxy: eliminate broker pid file
Browse files Browse the repository at this point in the history
Eliminate code to create broker.pid file as the
local connector no longer expects it and it serves
no other purpose.
  • Loading branch information
garlick committed Mar 2, 2017
1 parent 1191f6e commit 697d51e
Showing 1 changed file with 0 additions and 11 deletions.
11 changes: 0 additions & 11 deletions src/cmd/builtin/proxy.c
Original file line number Diff line number Diff line change
Expand Up @@ -902,7 +902,6 @@ static int cmd_proxy (optparse_t *p, int ac, char *av[])
const char *tmpdir = getenv ("TMPDIR");
char workpath[PATH_MAX + 1];
char sockpath[PATH_MAX + 1];
char pidfile[PATH_MAX + 1];
const char *job;
const char *optarg;
int optindex;
Expand Down Expand Up @@ -962,16 +961,6 @@ static int cmd_proxy (optparse_t *p, int ac, char *av[])
log_err_exit ("error creating proxy socket directory");
cleanup_push_string(cleanup_directory, workpath);

/* Write proxy pid to broker.pid file.
* Local connector expects this.
*/
n = snprintf (pidfile, sizeof (pidfile), "%s/broker.pid", workpath);
assert (n < sizeof (pidfile));
FILE *f = fopen (pidfile, "w");
if (!f || fprintf (f, "%d", getpid ()) < 0 || fclose (f) == EOF)
log_err_exit ("%s", pidfile);
cleanup_push_string(cleanup_file, pidfile);

/* Listen on socket
*/
n = snprintf (sockpath, sizeof (sockpath), "%s/local", workpath);
Expand Down

0 comments on commit 697d51e

Please sign in to comment.