Skip to content

Commit 9aa1fb9

Browse files
committed
fix build fail on ubuntu
1 parent 0a7ac78 commit 9aa1fb9

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

stable-diffusion-abi.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
#include "stable-diffusion-abi.h"
22

33
#include <string>
4+
#include <cstring>
45
#include <map>
56
/*================================================= StableDiffusion C API =============================================*/
67

@@ -232,6 +233,6 @@ const char* get_stable_diffusion_system_info() {
232233
std::string info = sd_get_system_info();
233234
size_t length = info.size() + 1;
234235
char* buffer = new char[length];
235-
memcpy(buffer, info.c_str(), length);
236+
std::memcpy(buffer, info.c_str(), length);
236237
return buffer;
237238
};

0 commit comments

Comments
 (0)