- 01
- 02
- 03
- 04
- 05
- 06
- 07
- 08
- 09
- 10
- 11
- 12
static int callback_from_db_message(void *data, int argc, char **argv, char **azColName) {
int *userSocket = data;
long time = atol(argv[1]);
bool edit = atoi(argv[2]);
char *sTime = mx_strnew(26);
ctime_r(&time, sTime);
char *buffer = new_messageClient1(argv[0], argv[3],sTime,edit);
usleep(10000);
int receive = send(*userSocket, buffer, mx_strlen(buffer), 0);
return argc - argc + mx_strlen(azColName[0] ? "" : "0") - mx_strlen(azColName[0] ? "" : "0");
}