Changeset 466 in flair-src for trunk/lib/FlairSimulator


Ignore:
Timestamp:
03/09/22 10:29:38 (9 months ago)
Author:
Sanahuja Guillaume
Message:

unlock memory in simulator to avoid mmap problems when running simulator as non root

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/lib/FlairSimulator/src/Gui_impl.cpp

    r365 r466  
    2929#include <unistd.h>
    3030#include <sstream>
     31#include <sys/mman.h>
    3132
    3233using namespace irr;
     
    8485  this->scene_width = scene_width;
    8586  this->scene_height = scene_height;
     87 
     88  //unlock memory for GL simulator, otherwise it can cause problems when running simlator as non root
     89  //(mmap can fail)
     90  //memory was locked by FrameworkManager_impl constructor
     91  munlockall();
    8692
    8793  device = createDevice(driver_type, dimension2d<u32>(app_width, app_height),16, false, false, false);
Note: See TracChangeset for help on using the changeset viewer.