Minetest logo

IRC log for #minetest-dev, 2015-04-17

| Channels | #minetest-dev index | Today | | Google Search | Plaintext

All times shown according to UTC.

Time Nick Message
00:02 proller joined #minetest-dev
00:13 proller joined #minetest-dev
00:18 est31 hmmmm, a question. There is srp_verifier_new and it writes to its param "const char ** username" with "*username = usr->username;". I dont need that value, I'd best like to pass NULL to the method. But then it will do dereference null right? The example makes a local variable only for this purpose, not using it afterwards.
00:18 paramat joined #minetest-dev
00:19 paramat hmmmm thanks for the commit, compiling latest results in a warning and an error: https://gist.github.com/paramat/5ac23a1e649a157bd77a
00:20 est31 paramat, wait, you mean master?
00:21 paramat yes
00:21 * est31 tries
00:22 est31 ouch
00:22 * est31 can reproduce
00:22 paramat phew
00:23 est31 breaking compilation is very bad: first all PRs break too and when people bisect they run into problems
00:29 est31 somehow it compiles for one configuration, and for another it doesnt
00:30 est31 pushing a fix if nobody minds
00:32 est31 in 4 mins
00:32 est31 (changing std::ifstream is(filename, std::ios_base::binary); into std::ifstream is(filename.c_str(), std::ios_base::binary);)
00:35 est31 ah now I know the reason
00:36 est31 hmmmm required c++11 lol
00:38 est31 pushed
00:44 paramat thanks
00:46 paramat now compiles
00:57 chchjesus joined #minetest-dev
01:00 Megaf_ joined #minetest-dev
01:08 hmmmm I did?
01:08 hmmmm est31: learn C
01:09 hmmmm est31:  I'd have to be looking at it to give you a real answer
01:10 deltib joined #minetest-dev
01:10 hmmmm paramat, sorry bout that will be fixing in the next patch
01:11 hmmmm oh... est31 already did it
01:11 * hmmmm grumbles
01:11 hmmmm okay i'll rebase.
01:12 paramat no problem
01:18 est31 hmmmm, nvm bout my question. Would have only spared one line.
01:39 Wayward_Tab joined #minetest-dev
01:40 hmmmm ask away
01:40 hmmmm if you have any language questions at all, please feel free to ask
01:40 hmmmm this is how you get better
01:42 hmmmm btw, you should have [WIP] in your PR title
01:42 est31 I have the WIP label
01:42 hmmmm ohh
01:42 hmmmm i didn't look at the label
01:43 hmmmm okay, looking... you mean ver->username?
01:44 hmmmm this is somewhat wacky code.  the style is weird and inconsistent.
01:44 est31 usr->username;
01:44 est31 and space idents
01:44 hmmmm that's in srp_user_new, you said srp_verifier_new
01:44 est31 sorry meant that
01:45 hmmmm hrm
01:45 est31 correcting again: meant srp_user_start_authentication
01:45 hmmmm I don't get it
01:45 hmmmm usr->username is a const char *, but then he disrespects that a couple of lines below by casting it to (char *)
01:46 hmmmm this doesn't seem like very high quality code to me...
01:48 hmmmm are you sure you don't need "username"?
01:48 est31 yes
01:48 hmmmm don't get what the point is of extracting it from SRPUser
01:48 est31 it has only been added so that you only have to store the SRPUser
01:49 est31 you can call ..._new at some other point
01:49 est31 then that method extracts it for you
01:49 hmmmm what the heck is the point of extracting the username from the SRPUser
01:49 hmmmm this makes no sense
01:50 hmmmm look, it does nothing but set username to the contents of that struct
01:50 hmmmm the caller could've just used usr->username if he wanted that
01:50 hmmmm I am starting to have my doubts about this library...
01:50 est31 the struct is "internal"
01:50 est31 it is only defined in the c file
01:51 hmmmm ahh i see
01:51 hmmmm I guess it makes sense then a little
01:51 hmmmm ahh that's why it's a const char
01:51 est31 ?
01:52 hmmmm okay, so if you're not using that value, you'd have to add an if statement to that
01:52 hmmmm you're saving a line, sure, but you're adding it somewhere else
01:53 hmmmm that's the way optional pointer parameters work.  if (username)\n\t*username = thing;
01:53 est31 ok thanks
01:53 hmmmm yeh your question makes total sense now with context
02:04 est31 argh
02:04 est31 translatePassword has wstring as its second param
02:05 est31 and in most places it is used, there is narrow_to_wide(param2)
02:05 est31 internally, its doing wide_to_narrow
02:05 est31 gonna refactor this
02:12 est31 hmmmm, do you plan a second patch?
02:12 est31 l_mapgen.cpp:1042:19: warning: unused variable ‘ndef’ [-Wunused-variable]
02:12 est31 INodeDefManager *ndef = getServer(L)->getNodeDefManager();
02:15 hmmmm ...yes.
02:15 est31 btw something else broke too "WARNING: Relative path not properly supported on this platform"
02:15 hmmmm you don't need to fix every single fart and cough within 5 minutes
02:15 est31 hmmmm, agreed
02:15 est31 that warning has time
02:16 proller joined #minetest-dev
02:16 est31 failure to build... bad
02:16 est31 due to the relative path problem I cant start the client
02:16 hmmmm that's not caused by my changes, that's for sure
02:17 est31 I'll fix it either way
02:17 est31 (not the warning)
02:17 est31 but the path detection problem
02:18 hmmmm okay
02:26 Hijiri joined #minetest-dev
02:27 paramat left #minetest-dev
02:50 est31 gcc is doing quite weird stuff here
02:51 est31 clang too
02:52 est31 I have found out that the issue was caused because when you pass "--std=c++11" to the compiler, the preprocessor macro "linux" isn't defined anymore
02:52 est31 so this makes the code in porting.cpp believe we aren't on linux
02:52 est31 but it isn't limited to ++11
02:53 est31 99 has the same issue
02:53 est31 or 98 for c++
02:55 hmmmm hrmm
02:55 hmmmm no comment
03:04 est31 pushing in 15 minutes http://pastie.org/10097239
03:04 hmmmm looks good to me
03:04 est31 then pushing faster :)
03:04 hmmmm in fact, I think the check for __linux was already there at one point
03:05 est31 blame it :p
03:05 hmmmm what happened to it?  did somebody remove that thinking they're simplifying code?
03:07 hmmmm humm no
03:07 hmmmm it was always like that
03:08 hmmmm i added __linux to the porting.h things
03:09 chchjesus joined #minetest-dev
03:10 est31 pushing now
03:11 est31 ugs
03:11 est31 srry wasnt compilation
03:12 est31 but path detection
03:12 est31 pushed
03:33 leat joined #minetest-dev
03:41 Hunterz joined #minetest-dev
03:57 Zeno` joined #minetest-dev
04:07 est31 Merging this small refactor in 15 minutes: http://pastie.org/10097280
04:07 est31 (removes trailing spaces & spares some string copies and conversions)
04:11 Zeno` :-o
04:16 Zeno` lgtm
04:17 est31 pushing now
04:47 Hijiri joined #minetest-dev
05:03 hmmmm https://github.com/minetest/minetest/commit/3576f4fab7267ff6d110fe94b6f397d6471a6980
05:03 hmmmm https://github.com/minetest/minetest/commit/406d9ba87b9f6e57b86c6282bf157e3341aa195c
05:12 est31 ok my srp port now passes through valgrind
05:15 est31 needs ~40 MB per run, this is very disturbing.
05:15 est31 either its gmp's fault or the hash function's
05:16 est31 (valgrind shows this under "$num allocated")
05:16 est31 err
05:16 est31 40 KB
05:17 est31 that seems ok to me
05:20 Zeno` joined #minetest-dev
05:33 hmmmm night. gotta get to sleep early because of an early-ass doctor's appointment
05:34 Zeno` have fun
05:34 hmmmm later
05:34 hmmmm pretty soon i'm going to take a break from FUCKIN' schematics
05:34 hmmmm i am frankly tired of it and it's in a decent spot right now
05:36 leat joined #minetest-dev
05:48 Hunterz joined #minetest-dev
06:09 cib0 joined #minetest-dev
06:23 Krock joined #minetest-dev
06:37 jin_xi joined #minetest-dev
07:16 err404 joined #minetest-dev
07:19 chchjesus joined #minetest-dev
07:19 cib0 joined #minetest-dev
07:20 kilbith joined #minetest-dev
08:01 Yepoleb_ joined #minetest-dev
08:22 est31 #2618
08:22 ShadowBot https://github.com/minetest/minetest/issues/2618 -- 20s timeout when connecting to server by SmallJoker
08:31 leat joined #minetest-dev
08:32 est31 pushing fix that Krock suggested
08:33 est31 pushed
08:33 Krock So you include a new header to get that single line working? :3
08:33 est31 } catch { doesnt compile for me
08:33 est31 so I included that header
08:33 Krock oh. maybe again a fault from my C# experience
08:37 est31 about your PR Krock, what was the result of your discussion with hmmm?
08:38 Krock est31, I added some lines to set last_time to the current time. It's fine now.
08:45 est31 +1ed it
08:47 Krock pls4push
08:47 est31 if you can point me to a comment by hmmm where he agrees on your PR, I'll do it
08:47 est31 or any other coredev
08:51 Krock http://irc.minetest.ru/minetest-dev/2015-04-16#i_4225474 and a day earlier: http://irc.minetest.ru/minetest-dev/2015-04-15#i_4223935
08:52 est31 Thats not 100% what I need.
08:53 est31 but I don't see how it could harm people
08:53 est31 Its not such a big change
08:53 leat joined #minetest-dev
08:54 Krock It's tested and it works without problems
08:55 est31 thats not the issue
08:55 est31 the issue is that there is a rule
08:55 est31 2 coredevs have to agree
08:56 est31 I think it should be changed to the point: coredevs can push things upstream if they are obvious or trivial.
08:56 est31 (I mean PRs, the rule already exists for own code)
09:02 est31 but I guess those two comments you linked qualify as +1
09:03 Krock kinda much trouble for that simple change :3
09:17 Megaf joined #minetest-dev
09:21 wilkgr joined #minetest-dev
09:27 Zeno` joined #minetest-dev
09:27 SudoAptGetPlay joined #minetest-dev
09:27 Zeno` Krock: https://github.com/minetest/minetest/blob/f5ae8e837e854007f1164ccd81872b6fe506a69d/src/game.cpp#L2245
09:28 Zeno` ^-- why is that line necessary?
09:31 MinetestForFun joined #minetest-dev
09:31 Zeno` I don't *think* it will cause problems, but strictly speaking getTimer()->getTime() should not be called unless immediately after the timer has been stepped or device->run() has been called
09:31 Zeno` there was no problem without it there
09:32 Zeno` (it won't crash or anything, I'm just not sure if there will be unwanted side-effects... there were none before it was added)
09:32 Zeno` oh well
09:41 cib0 joined #minetest-dev
09:41 Hunterz joined #minetest-dev
10:24 leat joined #minetest-dev
10:50 cib0 joined #minetest-dev
11:04 leat joined #minetest-dev
11:09 SudoAptGetPlay joined #minetest-dev
11:09 kilbith_ joined #minetest-dev
11:21 est31 joined #minetest-dev
11:25 leat joined #minetest-dev
11:29 proller joined #minetest-dev
12:12 VanessaE_ joined #minetest-dev
12:21 leat joined #minetest-dev
12:55 selat joined #minetest-dev
12:58 Krock joined #minetest-dev
13:16 Wayward_Tab joined #minetest-dev
13:18 twoelk joined #minetest-dev
14:00 twoelk joined #minetest-dev
14:02 kilbith joined #minetest-dev
14:16 MinetestForFun joined #minetest-dev
14:30 Hunterz joined #minetest-dev
15:04 Calinou joined #minetest-dev
15:29 hmmmm joined #minetest-dev
15:36 hmmmm krock wanted to make sure that last_time was set to the current time if it had not been initialized
15:36 hmmmm so he tried something like last_time = fpscontrol->last_time or current_time
15:37 hmmmm but that doesn't translate to C
15:37 hmmmm fpscontrol is zeroed out so the last time is always 0 on the first run, maxing out the dtime when limitFps is called
15:38 hmmmm but really fpscontrol->last_time should be initialized to the current time so there's no jump on the first cycle
15:46 SopaXorzTaker joined #minetest-dev
15:53 proller joined #minetest-dev
16:19 err404 joined #minetest-dev
16:22 Hunterz joined #minetest-dev
16:36 err404 joined #minetest-dev
16:59 leat joined #minetest-dev
17:04 kilbith joined #minetest-dev
17:17 leat joined #minetest-dev
17:42 Sokomine hmmmm: i've got a problem with the current git version.  minetest.create_schematic( start_pos, end_pos, nil, filename, nil)   crashes the game
17:49 Sokomine hmmmm: it also crashes when using worldedit (mtschemcreate)
18:03 Hijiri joined #minetest-dev
18:26 shadowzone joined #minetest-dev
18:39 Player_2 joined #minetest-dev
19:36 hmmmm hmm
19:36 hmmmm i'll take a look in a bit
19:51 Sokomine thank you
20:14 nore joined #minetest-dev
20:16 leat joined #minetest-dev
20:31 luizrpgluiz joined #minetest-dev
20:38 luizrpgluiz left #minetest-dev
20:52 SudoAptGetPlay joined #minetest-dev
20:55 Hijiri joined #minetest-dev
21:04 leat joined #minetest-dev
21:14 err404 joined #minetest-dev
21:28 chchjesus joined #minetest-dev
22:38 hmmmm oh yes oh yes!
22:38 proller joined #minetest-dev
22:40 hmmmm sokomine, fixed
22:40 hmmmm hmm odd
22:41 hmmmm i did not know you needed typeinfo and it worked for me so *shrug*
22:42 paramat joined #minetest-dev
22:44 paramat updated and simplified PR for river water game#493
22:44 ShadowBot https://github.com/minetest/minetest_game/issues/493 -- Default: Add river water by paramat
22:44 hmmmm it seems to be getting backlash
22:47 hmmmm yeah, if we were to implement these kinds of physics in the engine, how would it be done.. good question
22:55 paramat the resistence in the comments was to the original PR which had fresh water, fresh river water and mixed water, i now agree that was too complex
22:57 paramat if anyone knows the best way for a bucket of normal water to be returned when bucketing river water, let me know, i'll add to this PR
22:58 twoelk|2 joined #minetest-dev
23:00 Sokomine hmmmm: it works again. thanks :-)
23:04 MinetestForFun joined #minetest-dev
23:34 VanessaE joined #minetest-dev

| Channels | #minetest-dev index | Today | | Google Search | Plaintext