Commit Graph

3623 Commits

Author SHA1 Message Date
kwolekr 393345e6f7 SEnv: Remove static_exists from ActiveObjects in deleted blocks 2015-08-15 14:03:53 -04:00
nerzhul c4b5561b3f Remove unused function from connection.{cpp,h} 2015-08-15 08:48:20 +02:00
kwolekr be9024a397 minimap: Add ability to disable from server 2015-08-13 15:05:48 -04:00
est31 a670ecfde4 game.cpp: Update cached settings 2015-08-13 20:05:53 +02:00
Perttu Ahola def274a583 Fix segfault caused by a8e238ed06 2015-08-13 19:02:48 +03:00
est31 a8e238ed06 Add count based unload limit for mapblocks 2015-08-13 07:56:07 +02:00
kwolekr 2b04ab874d SAPI: Track last executed mod and include in error messages 2015-08-12 23:56:12 -04:00
est31 738fbc66d0 Fix Lua PcgRandom
Before, this lua code led to a crash:

local pcg = PcgRandom(42)
local value = pcg:next()

This was because if you called s32 PcgRandom::range(min, max) with the
minimum and maximum possible values for s32 integers (which the lua
binding code did), u32 PcgRandom::range(bound) got called with 0 as the
bound. The bound however is one above the maximum value, so 0 is a "special"
value to pass to this function. This commit fixes the lua crash by
assigning the RNG's full range to the bound 0, which is also fits to the
"maximum is bound - 1" principle, as (u32)-1 is the maximum value in the
u32 range.
2015-08-12 11:36:22 +02:00
paramat f0b325254f Treegen: Rename pine tree mapgen alias 2015-08-10 09:50:58 +01:00
Kahrl 6c0c27f662 Fix intlGUIEditBox leak and uninitialized value in Mapper (reported by valgrind) 2015-08-10 08:41:45 +02:00
kwolekr 1c408c4f1d Make NetworkPacket respect serialized string size limits 2015-08-10 02:16:55 -04:00
kwolekr 18cfd89a86 Display Lua memory usage at the time of Out-of-Memory error
Also misc. minor cleanups
2015-08-10 01:38:09 -04:00
rubenwardy a953ff4dfc Fix segfaults caused by the Environment not being initialized yet 2015-08-09 23:36:55 +02:00
Loic Blot 35cc90b086 Remove unused file 2015-08-09 13:27:42 +02:00
Kahrl 63b12f1f04 Fix camera updates being toggled by N key in release mode (#2762) 2015-08-07 06:02:06 +02:00
gregorycu 5c3c965c1a Fix detection of sneaking node
This fixes bug 1551
2015-08-06 03:14:56 -04:00
kwolekr 8560ece02e Fix BufferedPacket race condition (fixes #2983)
This was caused by the use the non-threadsafe SharedBuffer in a
threaded context.
2015-08-06 02:25:35 -04:00
kwolekr bd0b469d3d Fix critical vulnerabilities and bugs with NetworkPacket 2015-08-06 00:10:57 -04:00
est31 49cf66d785 Initialize random for verification key generation too 2015-08-06 05:48:07 +02:00
kwolekr bcf47bc67c Improve Script CPP API diagnostics 2015-08-05 21:13:03 -04:00
kwolekr 3183d5a403 connection: Make assertions non-fatal for received data 2015-08-05 21:01:13 -04:00
RealBadAngel 3295f3c401 Fix tiling issues for PLANTLIKE and FIRELIKE with FSAA 2015-08-05 22:52:32 +02:00
paramat 7a6e4dc54a Cavegen V6: Make all caves consistent with 0.4.12 stable
When tunnels entirely above ground were avoided, the
missing pseudorandom calls changed the allowed caves.
Now, above ground tunnels are not placed while
still running all previous pseudorandom calls.
2015-08-03 06:39:23 +01:00
paramat cf77e0333d Biome API: Make fallback biome stone and water, disable filler 2015-08-03 02:34:32 +01:00
Břetislav Štec abe6c072d6 src/util/numeric.{cpp,h}: Fix FacePositionCache data race 2015-08-02 19:42:22 +02:00
Miner59 060e56b24c Fix "bouncy" blocks
Before players "bounced" too high. Now, while still allowing to bounce, higher speed bounces are throttled.
2015-08-02 19:40:23 +02:00
Břetislav Štec 868a1a5c13 src/client/tile.cpp: Fix reference counting 2015-08-02 19:26:15 +02:00
rubenwardy ec796b8e81 Add map limit config option 2015-08-02 14:27:04 +02:00
Břetislav Štec a5e5aa5be9 Prepend "Lua: " before lua exceptions
src/server.cpp
src/emerge.cpp
2015-08-02 02:17:37 -04:00
Břetislav Štec c4287a0d68 src/wieldmesh.cpp: Fix mesh extrusion memory leak 2015-08-02 02:16:30 -04:00
Břetislav Štec ebe7b31538 src/client.cpp: Fix mapper memory leak 2015-08-02 02:15:38 -04:00
kwolekr 42cf5e972d Improve accuracy and safety of float serialization
Multiplying by a factor of 1/1000.f (rather than dividing by 1000.f) directly
introduces an error of 1 ULP.  With this patch, an exact comparison of a
floating point literal with the deserialized F1000 form representing it is now
guaranteed to be successful.
In addition, the maxmium and minimum safely representible floating point
numbers are now well-defined as constants.
2015-08-01 19:30:08 -04:00
kwolekr bf991bde45 Clean up util/serialization.{cpp,h} and add unit tests 2015-08-01 19:24:46 -04:00
Břetislav Štec 67997af67f src/environment.cpp: Fix NULL pointer dereference 2015-08-01 20:44:18 +02:00
Břetislav Štec 79e2647556 src/network/connection.h: Fix race condition 2015-08-01 20:44:17 +02:00
est31 c39a85a88d Android: Add githash header to spare rebuilds after new commits
Before, android_version.h got changed at every new commit. Now, we
only change it with new minetest releases. Analogous to how cmake
does it,  we add an android_version_githash.h file that communicates
the git hash to C++ code.

Also, unify VERS_MAJOR, VERS_MINOR and VERS_PATCH variable
calculation inside the whole makefile.
2015-08-01 20:42:07 +02:00
kwolekr 7919318be7 tests: Log exceptions thrown inside of unit tests 2015-07-31 23:30:25 -04:00
paramat cfed682d04 Dungeon generation: Fix code style issues in dungeongen.cpp 2015-08-01 00:37:26 +01:00
Loic Blot 05fe9ab2d4 Small SendableMediaAnnouncement cleanup
-> Remove the SendableMediaAnnouncement struct
-> Forge the packet directly in the m_media loop, spare one loop and the construction of a vector
-> Use preincrement to spare iterator copies
2015-07-31 01:01:00 +02:00
est31 eb3aac20c8 Android: fix horrible libiconv build
Before, our libiconv build was a joke. We first called configure for our own build host system,
then called make, before we executed a Android.mk script we provided as patch. The first "native make"
always failed, and the LIBICONV_LIB file setting in our Makefile didn't match the built one,
resulting in an always-rebuild of iconv.

This commit cleans up this total mess, removes the double-build, and the Android.mk, and properly calls
./configure with the according target platform, and uses a built toolchain.

As we have to deal with the android bug "NDK: Support for prebuild libs with full sonames"
https://code.google.com/p/android/issues/detail?id=55868
as the 2013 patch
https://lists.gnu.org/archive/html/libtool-patches/2013-06/msg00002.html
by Google's David Turner wasn't inside the 2011 libtool, we pass -avoid-version to
libtool.

Thanks to the proper build, wide_to_utf8 works for android now, removing us of the need to disable it.
2015-07-29 15:59:06 +02:00
nerzhul ca63f7f10d Precalculate mapblock relative size. This permit to remove many s16 calculs on runtime 2015-07-29 11:45:44 +02:00
Břetislav Štec 88a6b9f52d Fixed minimap memory leak 2015-07-27 11:06:46 -04:00
est31 f336d3ffb6 Fix srp.cpp:815 leak
Thanks @Zeno-
2015-07-27 08:15:39 +02:00
est31 c30a2d6854 Add AreaStore data structure 2015-07-27 06:42:56 +02:00
SmallJoker 454a290370 Fix MSVC number conversion warning 2015-07-25 17:38:04 +02:00
est31 fa1096ec49 Fix minetest.get_(all)_craft_recipe(s) regression
Since 03e0dd33a8 the calls didn't return an output count
for the recipes.
2015-07-25 17:33:41 +02:00
Loic Blot 4e6971e593 Cleanup server addparticle(spawner) by merge two identical functions. 2015-07-25 12:24:28 +02:00
est31 288302a1f0 Fix documentation of dedicated_server_loop 2015-07-24 23:11:19 +02:00
est31 5bde7798e9 Check output of mpz_set_str and fix leak on error condition
Also add static identifier as upstream did
2015-07-24 22:42:54 +02:00
Loic Blot aab7c83d02 Remove some old dead code. Fix some Clang warnings in SRP (ng->N... will
always evaluate to true.
2015-07-24 21:48:02 +02:00