Change base dir to /djumbai instead of /opt/djumbai
This commit is contained in:
parent
5c28fe0531
commit
21a222d855
6 changed files with 22 additions and 23 deletions
|
|
@ -42,7 +42,7 @@ int main() {
|
|||
deserialize_message(buffer, MESSAGE_SIZE, &msg);
|
||||
|
||||
if (msg.header.isgroup) {
|
||||
const char *directory_format = "/opt/djumbai/group/%d/message_box";
|
||||
const char *directory_format = "/djumbai/group/%d/message_box";
|
||||
char directory[PATH_MAX];
|
||||
snprintf(directory, sizeof(directory), directory_format, msg.header.receiver);
|
||||
|
||||
|
|
@ -58,7 +58,7 @@ int main() {
|
|||
write_message_to_file(directory, timestamp_str, 0020, buffer);
|
||||
|
||||
} else {
|
||||
const char *directory_format = "/opt/djumbai/user/%d/message_box/%d";
|
||||
const char *directory_format = "/djumbai/user/%d/message_box/%d";
|
||||
char directory[PATH_MAX];
|
||||
snprintf(directory, sizeof(directory), directory_format, msg.header.receiver,
|
||||
msg.header.sender);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue