Skip to content

Commit 637ae9c

Browse files
author
Vladimir Ershov
committed
fix pg_attr
1 parent 7dbdedd commit 637ae9c

File tree

4 files changed

+9
-2
lines changed

4 files changed

+9
-2
lines changed

src/cron_string.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
#include <stdarg.h>
55
#include "cron_string.h"
66
#include "postgres.h"
7+
#include "c.h"
78
#include "port.h"
89

910

src/cron_string.h

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,8 @@
55
#include <stdlib.h>
66
#include <string.h>
77
#include <stdarg.h>
8+
#include "postgres.h"
9+
#include "port.h"
810

911
extern int cps_error;
1012

@@ -41,7 +43,7 @@ typedef struct {
4143
} cron_ent_t;
4244

4345
void destroyCronEnt(cron_ent_t *);
44-
void _cps_set_error(int num, const char *message, ...) __attribute__ ((format (gnu_printf, 2, 3)));;
46+
void _cps_set_error(int num, const char *message, ...) pg_attribute_printf(2, 3);
4547
char *get_cps_error(void);
4648
int _cps_string_has(char *str, char c);
4749
char *_cps_append_string(char *str, char *to_add);

src/pgpro_scheduler.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -567,6 +567,7 @@ cron_string_to_json_text(PG_FUNCTION_ARGS)
567567
elog(ERROR, "unknown error: %d", cps_error);
568568
}
569569
}
570+
PG_RETURN_NULL();
570571
}
571572

572573

src/scheduler_job.h

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@
77
#include <stdarg.h>
88
#include "utils/timestamp.h"
99
#include "memutils.h"
10+
#include "c.h"
11+
#include "port.h"
1012

1113
typedef struct {
1214
int cron_id;
@@ -30,7 +32,8 @@ typedef struct {
3032
job_t *init_scheduler_job(job_t *j);
3133
job_t *get_expired_jobs(char *nodename, int *n, int *is_error);
3234
job_t *get_jobs_to_do(char *nodename, int *n, int *is_error);
33-
job_t *set_job_error(job_t *j, const char *fmt, ...) __attribute__ ((format (gnu_printf, 2, 3)));;
35+
/*job_t *set_job_error(job_t *j, const char *fmt, ...) __attribute__ ((format (gnu_printf, 2, 3)));;*/
36+
job_t *set_job_error(job_t *j, const char *fmt, ...) pg_attribute_printf(2, 3);
3437
int move_job_to_log(job_t *j, bool status);
3538
void destroy_job(job_t *j, int selfdestroy);
3639

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy