Silence spurious warnings

None of these are actual bugs as far as I can tell.
This commit is contained in:
Nunuhara Cabbage
2025-06-23 19:04:52 -07:00
parent 3ef7ce926b
commit ffb9fbae31
6 changed files with 11 additions and 5 deletions
+1 -1
View File
@@ -943,7 +943,7 @@ void particle_object_calc_local_transform(struct RE_instance *inst, struct parti
struct pae_object *pae_obj = po->pae_obj;
float t = glm_percent(pi->begin_frame, pi->end_frame, frame);
vec3 pos, up_vector;
vec3 pos = {0}, up_vector;
calc_pos_and_up_vector(po, pi, t, pos, up_vector);
float rel_frame = frame - pi->begin_frame;
+1 -1
View File
@@ -31,7 +31,7 @@ static struct bgi bgi_data[BGI_MAX];
static char *bgi_gets(char *buf, int n, FILE *fp)
{
char *s = buf;
int c;
int c = EOF;
while (--n > 0 && (c = fgetc(fp)) != EOF) {
c = c >> 4 | (c & 0xf) << 4; // decrypt
*s++ = c;
+3
View File
@@ -395,7 +395,10 @@ void hll_call(int libno, int fno)
stack_push(slot);
break;
case AIN_BOOL:
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wstrict-aliasing"
stack_push(*(bool*)&r);
#pragma GCC diagnostic pop
break;
default:
stack_push(r);
+3 -2
View File
@@ -15,6 +15,7 @@
*/
#include <stdint.h>
#include <limits.h>
#include "hll.h"
#include "vm/page.h"
@@ -408,7 +409,7 @@ static int vmArray_GrepLowOrder(struct page *s_array, int index, struct page **d
if (index < 0)
VM_ERROR("not implemented");
int min_index = -1, min_value;
int min_index = -1, min_value = INT_MAX;
for (int i = index; i < s_array->nr_vars; i++) {
if (d_array->values[i].i)
continue;
@@ -434,7 +435,7 @@ static int vmArray_GrepHighOrder(struct page *s_array, int index, struct page **
if (index < 0)
VM_ERROR("not implemented");
int max_index = -1, max_value;
int max_index = -1, max_value = INT_MIN;
for (int i = index; i < s_array->nr_vars; i++) {
if (d_array->values[i].i)
continue;
+2
View File
@@ -417,6 +417,7 @@ int vm_save_image(const char *key, const char *path)
case SAVE_FORMAT_JSON:
return save_json_image(key, path);
}
return 0;
}
#define _invalid_save_data(file, func, line, fmt, ...) \
@@ -1028,4 +1029,5 @@ int vm_write_image_comments(const char *key, const char *path, struct page *comm
case SAVE_FORMAT_JSON:
return write_json_image_comments(key, path, comments);
}
return 0;
}