Deleted Added
full compact
sanitytest.c (1.1.1.2) sanitytest.c (1.1.1.1)
1/*
2 * Copyright 2015-2016 The OpenSSL Project Authors. All Rights Reserved.
3 *
4 * Licensed under the OpenSSL license (the "License"). You may not use
5 * this file except in compliance with the License. You can obtain a copy
6 * in the file LICENSE in the source distribution or at
7 * https://www.openssl.org/source/license.html
8 */

--- 30 unchanged lines hidden (view full) ---

39int main()
40{
41 char *p;
42 char bytes[sizeof(p)];
43 int failures = 0;
44
45 /* Is NULL equivalent to all-bytes-zero? */
46 p = NULL;
1/*
2 * Copyright 2015-2016 The OpenSSL Project Authors. All Rights Reserved.
3 *
4 * Licensed under the OpenSSL license (the "License"). You may not use
5 * this file except in compliance with the License. You can obtain a copy
6 * in the file LICENSE in the source distribution or at
7 * https://www.openssl.org/source/license.html
8 */

--- 30 unchanged lines hidden (view full) ---

39int main()
40{
41 char *p;
42 char bytes[sizeof(p)];
43 int failures = 0;
44
45 /* Is NULL equivalent to all-bytes-zero? */
46 p = NULL;
47 memset(bytes, 0, sizeof(bytes));
47 memset(bytes, 0, sizeof bytes);
48 TEST(memcmp(&p, bytes, sizeof(bytes)) == 0);
49
50 /* Enum size */
51 TEST(sizeof(enum smallchoices) == sizeof(int));
52 TEST(sizeof(enum medchoices) == sizeof(int));
53 TEST(sizeof(enum largechoices) == sizeof(int));
54 /* Basic two's complement checks. */
55 TEST(~(-1) == 0);

--- 12 unchanged lines hidden ---
48 TEST(memcmp(&p, bytes, sizeof(bytes)) == 0);
49
50 /* Enum size */
51 TEST(sizeof(enum smallchoices) == sizeof(int));
52 TEST(sizeof(enum medchoices) == sizeof(int));
53 TEST(sizeof(enum largechoices) == sizeof(int));
54 /* Basic two's complement checks. */
55 TEST(~(-1) == 0);

--- 12 unchanged lines hidden ---