On 2024/05/19 17:13:05 -0400, Thomas Frohwein <tfrohw...@fastmail.com> wrote: > Can we do the same check for -lt like with chromium? The reason is that > I don't think the datasize should be reduced if the user has set it > higher than the 2G.
fwiw I prefer it too. > As in this counter diff: chiming in only for a small nitpick: > [...] > + if [ -x "$pyrogenesis" ] ; then > ++ DATASIZE=$((2 * 1024 * 1024)) > ++ if [ $(ulimit -Sd) -lt ${DATASIZE} ]; then > ++ ulimit -Sd ${DATASIZE} || \ > ++ ${X11BASE}/bin/xmessage -file - -center -buttons yes:0,no:1 -default > no <<- _EOF > ++ Cannot increase datasize-cur to at least ${DATASIZE} > ++ Do you want to run 0.A.D. anyway? this should really be "0 A.D." :P > ++ (If so, it may run out of memory and crash.) > ++ _EOF > ++ [ $? -eq 0 ] || exit > ++ fi > + "$pyrogenesis" "$@" > + else > + echo "Error: pyrogenesis not found in ($PATH)"