Skip to content
Snippets Groups Projects
Commit 881cb5e1 authored by Deucе's avatar Deucе :ok_hand_tone4:
Browse files

Use use strlcpy() in x_cio.c without the wrapper.

Reverts gen_defs/genwrap craziness.
parent c64357b9
Branches
Tags
1 merge request!455Update branch with changes from master
Pipeline #6261 passed
...@@ -107,7 +107,7 @@ void x_setname(const char *name) ...@@ -107,7 +107,7 @@ void x_setname(const char *name)
struct x11_local_event ev = {0}; struct x11_local_event ev = {0};
ev.type=X11_LOCAL_SETNAME; ev.type=X11_LOCAL_SETNAME;
SAFECOPY(ev.data.name, name); strlcpy(ev.data.name, name, sizeof(ev.data.name));
write_event(&ev); write_event(&ev);
} }
...@@ -116,7 +116,7 @@ void x_settitle(const char *title) ...@@ -116,7 +116,7 @@ void x_settitle(const char *title)
struct x11_local_event ev = {0}; struct x11_local_event ev = {0};
ev.type=X11_LOCAL_SETTITLE; ev.type=X11_LOCAL_SETTITLE;
SAFECOPY(ev.data.title, title); strlcpy(ev.data.title, title, sizeof(ev.data.title));
write_event(&ev); write_event(&ev);
} }
......
...@@ -551,6 +551,4 @@ typedef struct { ...@@ -551,6 +551,4 @@ typedef struct {
#include <SDL.h> #include <SDL.h>
#endif #endif
#include "genwrap.h" // For strlcpy()/strlcat() -- yes, it needs to be down here.
#endif /* Don't add anything after this #endif statement */ #endif /* Don't add anything after this #endif statement */
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment