소스 검색

[Minor] Convert some enums to static macros

tags/1.8.2
Vsevolod Stakhov 5 년 전
부모
커밋
ccc9d0065d
5개의 변경된 파일13개의 추가작업 그리고 15개의 파일을 삭제
  1. 1
    1
      contrib/librdns/rdns.h
  2. 7
    7
      src/libcryptobox/blake2/blake2.h
  3. 2
    3
      src/libcryptobox/chacha20/chacha.h
  4. 2
    3
      src/libcryptobox/poly1305/ref-64.c
  5. 1
    1
      src/libutil/addr.c

+ 1
- 1
contrib/librdns/rdns.h 파일 보기

@@ -105,7 +105,7 @@ union rdns_reply_element_un {

struct rdns_reply_entry {
union rdns_reply_element_un content;
uint16_t type;
enum rdns_request_type type;
int32_t ttl;
struct rdns_reply_entry *prev, *next;
};

+ 7
- 7
src/libcryptobox/blake2/blake2.h 파일 보기

@@ -20,13 +20,13 @@
extern "C" {
#endif

enum blake2b_constant {
BLAKE2B_BLOCKBYTES = 128,
BLAKE2B_OUTBYTES = 64,
BLAKE2B_KEYBYTES = 64,
BLAKE2B_SALTBYTES = 16,
BLAKE2B_PERSONALBYTES = 16
};
#define BLAKE2B_BLOCKBYTES 128
#define BLAKE2B_OUTBYTES 64
#define BLAKE2B_KEYBYTES 64
#define BLAKE2B_SALTBYTES 16
#define BLAKE2B_PERSONALBYTES 16

typedef struct blake2b_state_t {
unsigned char opaque[256];

+ 2
- 3
src/libcryptobox/chacha20/chacha.h 파일 보기

@@ -26,9 +26,8 @@
#ifndef CHACHA_H_
#define CHACHA_H_

enum chacha_constants {
CHACHA_BLOCKBYTES = 64,
};

#define CHACHA_BLOCKBYTES 64

typedef struct chacha_state_internal_t {
unsigned char s[48];

+ 2
- 3
src/libcryptobox/poly1305/ref-64.c 파일 보기

@@ -7,9 +7,8 @@
#include "config.h"
#include "poly1305.h"
#include "poly1305_internal.h"
enum {
POLY1305_BLOCK_SIZE = 16
};

#define POLY1305_BLOCK_SIZE 16

typedef struct poly1305_state_ref_t {
uint64_t r[3];

+ 1
- 1
src/libutil/addr.c 파일 보기

@@ -1055,7 +1055,7 @@ rspamd_inet_address_listen (const rspamd_inet_addr_t *addr, gint type,
}
}

if (type != SOCK_DGRAM) {
if (type != (int)SOCK_DGRAM) {

if (addr->af == AF_UNIX) {
path = addr->u.un->addr.sun_path;

Loading…
취소
저장