mirror of
https://github.com/intel/compute-runtime.git
synced 2026-01-04 23:56:39 +08:00
fix: adjust SysCalls::write signature to match stdlib
Signed-off-by: Artur Harasimiuk <artur.harasimiuk@intel.com>
This commit is contained in:
committed by
Compute-Runtime-Automation
parent
deb10999e1
commit
8d28f8d90e
@@ -86,7 +86,7 @@ int (*sysCallsReadlink)(const char *path, char *buf, size_t bufsize) = nullptr;
|
||||
int (*sysCallsIoctl)(int fileDescriptor, unsigned long int request, void *arg) = nullptr;
|
||||
int (*sysCallsPoll)(struct pollfd *pollFd, unsigned long int numberOfFds, int timeout) = nullptr;
|
||||
ssize_t (*sysCallsRead)(int fd, void *buf, size_t count) = nullptr;
|
||||
ssize_t (*sysCallsWrite)(int fd, void *buf, size_t count) = nullptr;
|
||||
ssize_t (*sysCallsWrite)(int fd, const void *buf, size_t count) = nullptr;
|
||||
int (*sysCallsPipe)(int pipeFd[2]) = nullptr;
|
||||
int (*sysCallsFstat)(int fd, struct stat *buf) = nullptr;
|
||||
char *(*sysCallsRealpath)(const char *path, char *buf) = nullptr;
|
||||
@@ -345,7 +345,7 @@ ssize_t read(int fd, void *buf, size_t count) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
ssize_t write(int fd, void *buf, size_t count) {
|
||||
ssize_t write(int fd, const void *buf, size_t count) {
|
||||
if (sysCallsWrite != nullptr) {
|
||||
return sysCallsWrite(fd, buf, count);
|
||||
}
|
||||
|
||||
@@ -29,7 +29,7 @@ extern int (*sysCallsReadlink)(const char *path, char *buf, size_t bufsize);
|
||||
extern int (*sysCallsIoctl)(int fileDescriptor, unsigned long int request, void *arg);
|
||||
extern int (*sysCallsPoll)(struct pollfd *pollFd, unsigned long int numberOfFds, int timeout);
|
||||
extern ssize_t (*sysCallsRead)(int fd, void *buf, size_t count);
|
||||
extern ssize_t (*sysCallsWrite)(int fd, void *buf, size_t count);
|
||||
extern ssize_t (*sysCallsWrite)(int fd, const void *buf, size_t count);
|
||||
extern int (*sysCallsPipe)(int pipeFd[2]);
|
||||
extern int (*sysCallsFstat)(int fd, struct stat *buf);
|
||||
extern char *(*sysCallsRealpath)(const char *path, char *buf);
|
||||
|
||||
Reference in New Issue
Block a user