diff options
Diffstat (limited to 'upgrade.c')
-rw-r--r-- | upgrade.c | 12 |
1 files changed, 6 insertions, 6 deletions
@@ -58,16 +58,16 @@ void mog_upgrade_prepare(int argc, char *argv[], char *envp[]) } /* writes one comma-delimited fd to fp */ -static bool emit_fd(FILE *fp, int fd) +static bool emit_fd(FILE *fp, struct mog_fd *mfd) { int r; /* no error, just the FD isn't used */ - if (fd < 0) + if (mfd == NULL) return true; errno = 0; - r = fprintf(fp, "%d,", fd); + r = fprintf(fp, "%d,", mfd->fd); if (r > 0) return true; if (errno == 0) @@ -81,9 +81,9 @@ static bool svc_emit_fd_i(void *svcptr, void *_fp) FILE *fp = _fp; struct mog_svc *svc = svcptr; - return (emit_fd(fp, svc->mgmt_fd) - && emit_fd(fp, svc->http_fd) - && emit_fd(fp, svc->httpget_fd)); + return (emit_fd(fp, svc->mgmt_mfd) + && emit_fd(fp, svc->http_mfd) + && emit_fd(fp, svc->httpget_mfd)); } /* returns the PID of the newly spawned child */ |