[PD-cvs] pd/src s_inter.c,1.1.1.3.2.19,1.1.1.3.2.20
Tim Blechmann
timblech at users.sourceforge.net
Thu Oct 21 10:12:15 CEST 2004
Update of /cvsroot/pure-data/pd/src
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv19201
Modified Files:
Tag: devel_0_37
s_inter.c
Log Message:
tweaking memlock
Index: s_inter.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/s_inter.c,v
retrieving revision 1.1.1.3.2.19
retrieving revision 1.1.1.3.2.20
diff -C2 -d -r1.1.1.3.2.19 -r1.1.1.3.2.20
*** s_inter.c 20 Oct 2004 10:44:59 -0000 1.1.1.3.2.19
--- s_inter.c 21 Oct 2004 08:12:13 -0000 1.1.1.3.2.20
***************
*** 675,678 ****
--- 675,682 ----
#endif
+ #ifdef _POSIX_MEMLOCK
+ #include <sys/resource.h>
+ #endif
+
void sys_set_priority(int higher)
{
***************
*** 693,696 ****
--- 697,706 ----
#ifdef _POSIX_MEMLOCK
+ /* tb: force memlock to physical memory */
+ struct rlimit mlock_limit;
+ mlock_limit.rlim_cur=0;
+ mlock_limit.rlim_max=0;
+ setrlimit(RLIMIT_MEMLOCK,&mlock_limit);
+ /* } tb */
if (mlockall(MCL_FUTURE) != -1)
fprintf(stderr, "memory locking enabled.\n");
***************
*** 909,913 ****
"TCL_LIBRARY=\"%s/tcl/library\" TK_LIBRARY=\"%s/tk/library\" \
\"%s/pd-gui\" %d\n",
! sys_libdir->s_name, sys_libdir->s_name, guidir, portno);
#endif
sys_guicmd = cmdbuf;
--- 919,923 ----
"TCL_LIBRARY=\"%s/tcl/library\" TK_LIBRARY=\"%s/tk/library\" \
\"%s/pd-gui\" %d\n",
! sys_libdir->s_name, sys_libdir->s_name, guidir,portno);
#endif
sys_guicmd = cmdbuf;
More information about the Pd-cvs
mailing list