Skip to content

Commit 588ece0

Browse files
authored
Merge pull request #117 from cgzones/specifier
Add misc qualifiers
2 parents e90892e + 6495f4d commit 588ece0

File tree

5 files changed

+5
-5
lines changed

5 files changed

+5
-5
lines changed

src/netlog/netlog-conf.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ int config_parse_netlog_remote_address(const char *unit,
3232

3333
r = socket_address_parse(&m->address, rvalue);
3434
if (r < 0) {
35-
struct addrinfo hints = {
35+
const struct addrinfo hints = {
3636
.ai_flags = AI_NUMERICSERV|AI_ADDRCONFIG,
3737
.ai_socktype = SOCK_DGRAM,
3838
.ai_family = socket_ipv6_is_supported() ? AF_UNSPEC : AF_INET,

src/share/log.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,7 @@ int log_format_iovec(
124124
bool newline_separator,
125125
int error,
126126
const char *format,
127-
va_list ap);
127+
va_list ap) _printf_(6,0);
128128

129129
/* This modifies the buffer passed! */
130130
int log_dump_internal(

src/share/ratelimit.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ static inline void ratelimit_reset(RateLimit *rl) {
1818
rl->num = rl->begin = 0;
1919
}
2020

21-
static inline bool ratelimit_configured(RateLimit *rl) {
21+
static inline bool ratelimit_configured(const RateLimit *rl) {
2222
return rl->interval > 0 && rl->burst > 0;
2323
}
2424

src/share/stat-util.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ int is_dir(const char* path, bool follow) {
3232
return !!S_ISDIR(st.st_mode);
3333
}
3434

35-
bool null_or_empty(struct stat *st) {
35+
bool null_or_empty(const struct stat *st) {
3636
assert(st);
3737

3838
if (S_ISREG(st->st_mode) && st->st_size <= 0)

src/share/stat-util.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212

1313
int is_dir(const char *path, bool follow);
1414

15-
bool null_or_empty(struct stat *st) _pure_;
15+
bool null_or_empty(const struct stat *st) _pure_;
1616

1717
int files_same(const char *filea, const char *fileb);
1818

0 commit comments

Comments
 (0)