<commit_before>#ifdef __linux__

#include "LinuxDolphinProcess.h"
#include "../../Common/CommonUtils.h"

#include <cstring>
#include <dirent.h>
#include <fstream>
#include <sstream>
#include <string>
#include <sys/uio.h>

namespace DolphinComm
{
bool LinuxDolphinProcess::findEmuRAMStartAddress()
{
  std::ifstream theMapsFile("/proc/" + std::to_string(m_PID) + "/maps");
  std::string line;
  while (getline(theMapsFile, line))
  {
    if (line.length() > 73)
    {
      if (line.substr(73, 19) == "/dev/shm/dolphinmem")
      {
        u64 firstAddress = 0;
        u64 SecondAddress = 0;
        std::string firstAddressStr("0x" + line.substr(0, 12));
        std::string secondAddressStr("0x" + line.substr(13, 12));

        firstAddress = std::stoul(firstAddressStr, nullptr, 16);
        SecondAddress = std::stoul(secondAddressStr, nullptr, 16);

        u64 test = SecondAddress - firstAddress;<commit_msg>DolphinProcess Fix a compatibility issue on Dolphin 5.0-5728 (Linux)<commit_after>#ifdef __linux__

#include "LinuxDolphinProcess.h"
#include "../../Common/CommonUtils.h"

#include <cstring>
#include <dirent.h>
#include <fstream>
#include <sstream>
#include <string>
#include <sys/uio.h>

namespace DolphinComm
{
bool LinuxDolphinProcess::findEmuRAMStartAddress()
{
  std::ifstream theMapsFile("/proc/" + std::to_string(m_PID) + "/maps");
  std::string line;
  while (getline(theMapsFile, line))
  {
    if (line.length() > 73)
    {
      if (line.substr(73, 19) == "/dev/shm/dolphinmem" ||
          line.substr(73, 20) == "/dev/shm/dolphin-emu")
      {
        u64 firstAddress = 0;
        u64 SecondAddress = 0;
        std::string firstAddressStr("0x" + line.substr(0, 12));
        std::string secondAddressStr("0x" + line.substr(13, 12));

        firstAddress = std::stoul(firstAddressStr, nullptr, 16);
        SecondAddress = std::stoul(secondAddressStr, nullptr, 16);

        u64 test = SecondAddress - firstAddress;
{'fraction_non_alphanumeric': 0.15416238437821173, 'fraction_numerical': 0.0328879753340185, 'mean_word_length': 3.6915662650602408, 'pattern_counts': {'":': 0, '<': 15, '<?xml version=': 0, '>': 17, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '249389', 'n_tokens_mistral': 724, 'n_tokens_neox': 657, 'n_words': 138}