Skip to content

Commit

Permalink
Merge pull request managarm#625 from Dennisbonke/get-resource-usage
Browse files Browse the repository at this point in the history
  • Loading branch information
no92 authored Feb 18, 2024
2 parents b6c4ebb + 5fdaa41 commit f845829
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion posix/subsystem/src/requests.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -341,14 +341,15 @@ async::result<void> serveRequests(std::shared_ptr<Process> self,
}else{
std::cout << "\e[31mposix: GET_RESOURCE_USAGE mode is not supported\e[39m"
<< std::endl;
user_time = 0;
// TODO: Return an error response.
}

helix::SendBuffer send_resp;

managarm::posix::SvrResponse resp;
resp.set_error(managarm::posix::Errors::SUCCESS);
resp.set_ru_user_time(stats.userTime);
resp.set_ru_user_time(user_time);

auto ser = resp.SerializeAsString();
auto &&transmit = helix::submitAsync(conversation, helix::Dispatcher::global(),
Expand Down

0 comments on commit f845829

Please sign in to comment.