--- Log opened Sun Oct 30 00:00:28 2016 20161030 00:06:05< stikonas> vultraz: GR is fun :) 20161030 00:06:34< stikonas> although less fun when you need to find a job... even in academia... not that much funding 20161030 00:07:58< vultraz> really? 20161030 00:08:22< vultraz> I would think there would be academic funding for research. 20161030 00:09:11< tad_carlucci> yeah. my brother alternates between doing acoustics and theoretic physics. The one pays the bills for the other. 20161030 00:17:10< celticminstrel> Actually, it would be possible to put those functions in the string metatable but not in the global string table. 20161030 00:17:20< DeFender1031> how? 20161030 00:18:05< celticminstrel> Copy the functions from the global string table to a new table, add the functions there, and set it as the string metatable. Something like that. There'd be some things to work out though. 20161030 00:18:19< celticminstrel> For starters, copying is probably not the best way... 20161030 00:18:28< DeFender1031> can you change the metatable for the built-in types? 20161030 00:18:32< celticminstrel> Yes. 20161030 00:18:36< DeFender1031> oh 20161030 00:18:44< celticminstrel> That's how the global string table becomes the string metatable in the first place. 20161030 00:18:44< DeFender1031> well, you wouldn't need to copy 20161030 00:18:55< celticminstrel> (You can only do it from C++ though, I think.) 20161030 00:19:01< DeFender1031> just set the metatable's metatable to the global string 20161030 00:19:52< celticminstrel> Something like that, but if I recall correctly that wouldn't "just work" without some additional work... 20161030 00:19:58< DeFender1031> so you'd have string type's metatable being wesnoth string table, and wesnoth string table's metatable being the global string table. 20161030 00:20:03< DeFender1031> hmm 20161030 00:20:21< celticminstrel> I seem to recall that in that event it's the middle metatable that's passed as "self" instead of the "instance", but I could be wrong. 20161030 00:20:49< DeFender1031> oh... 20161030 00:20:51< DeFender1031> hmm 20161030 00:21:13< DeFender1031> what if it was the __index instead? 20161030 00:21:17< DeFender1031> oh wait 20161030 00:21:19< DeFender1031> nevermind 20161030 00:21:27< DeFender1031> that's just about the stupidest question i've ever asked. 20161030 00:25:58< celticminstrel> Heh. 20161030 00:26:16< celticminstrel> Actually I tried to do something like that with the unit proxy metatable and it didn't work. 20161030 00:27:46 * celticminstrel pokes gfgtdf on the topic I pinged you about earlier. 20161030 00:27:57< celticminstrel> (Which happens to be the same thing we're discussing now, but...) 20161030 00:28:20< celticminstrel> (I can paste if you don't want to check logs.) 20161030 00:28:29< tad_carlucci> Which metatable you use depends upon what you're trying to accomplish. Adding to the string table, for instance, just adds a string.function but does not effect strings or add the ability to go to the global table and find a wesnoth string 20161030 00:29:04< celticminstrel> tad_carlucci: Well, the question is whether it's okay to add functions to the global string table. 20161030 00:29:04< gfgtdf> celticminstrel: ? 20161030 00:29:12< celticminstrel> gfgtdf: Like I just said. 20161030 00:29:15< gfgtdf> celticminstrel: about unit metatables ? 20161030 00:29:23< celticminstrel> No, about strings. 20161030 00:29:29< tad_carlucci> You see people add metatable entries a lot. 20161030 00:29:56< celticminstrel> vultraz said it would be confusing, and I was hesitant about it for several reasons, but I think it would be nice to put things like "split" and "trim" there. 20161030 00:30:01< celticminstrel> s/several/similar/ 20161030 00:32:02< tad_carlucci> I could add a "square root of imaginary numbers" function (sin) to string. string.fin(...) would call it. That doesn't mean it makes sense there. 20161030 00:32:19< celticminstrel> Well yeah. 20161030 00:32:57< gfgtdf> celticminstrel: my first thought is that i'd agree with vultraz, when i have a function in the string table i'd execpot that that i can find the documention at the official lua documentation. 20161030 00:33:36< tad_carlucci> Most likely the place to add things are the wesnoth tables. wesnoth.unit["Delfador"] for example should be doable. Whether it's pure Lua or calls into C++ is am implementation detail. 20161030 00:34:06< celticminstrel> Putting string manipulation functions in the wesnoth table seems a bit silly. 20161030 00:34:55< DeFender1031> gfgtdf, celticminstrel, vultraz, on the other hand, lua's built-in stuff is so bare bones, it's probably not hard to memorize a complete list of built in functions and know what isn't built in. 20161030 00:34:58< tad_carlucci> What functions are you considering? string.namedFormatting() to do that feature request, sounds reasonable. 20161030 00:35:26< DeFender1031> anyway, i'm off to bed for now. 20161030 00:35:28< celticminstrel> tad_carlucci: The functions I was considering are currently implemented in data/lua/wml-utils.lua - trim, split, and parenthetical_split. 20161030 00:35:43< DeFender1031> see y'all tomorrow 20161030 00:35:47< celticminstrel> The first two are fairly simple, mind you. 20161030 00:36:30< tad_carlucci> Ah. Well if they work on Lua strings, then string is the palce for them. But if they require wesnoth strings then I'd suggest something like wesnoth.string.split() 20161030 00:38:48< tad_carlucci> Remember, Lua strings can have embedded nuls (\0) so if you're making a Lua string function you'll want to consider that working on a lstring instead of a C string. 20161030 00:42:28< gfgtdf> celticminstrel: why woudl you want to move those implementation to c++? the lua implementation is quite trivial 20161030 00:44:15< vultraz> gfgtdf: I think he's thinking about reducing duplicate implementations of stuff between lua and c++ 20161030 00:44:23< vultraz> like parenthetical_split 20161030 00:44:34< vultraz> and just happened to come across this 20161030 00:44:36< vultraz> idk 20161030 00:44:40< vultraz> celticminstrel: is that accurate 20161030 00:46:31< gfgtdf> vultraz: well yes but the lua implementation is afaik a oneliner, and te c++ impletation woudl sureley be more complicated even of it just calls the c++ split function 20161030 00:47:19< vultraz> yeah 20161030 00:51:53< tad_carlucci> The only trick with doing a pure Lua implementation is loading the .lua file early enough so it's always there. 20161030 00:54:06< celticminstrel> gfgtdf: Code deduplication. 20161030 00:54:18< celticminstrel> tad_carlucci: Good point about nulls, though C++ strings can have that too. 20161030 00:54:40< celticminstrel> gfgtdf: split and trim are one-liners, yes. 20161030 00:55:24< celticminstrel> tad_carlucci: I'm not sure if there's a way to guarantee that a lua file is always loaded. Currently AFAIK it might be possible to define a custom core that doesn't load all the WML tag definitions. 20161030 00:56:33< celticminstrel> (Speaking of C++ strings and nulls, that's why you should never do lua_pushstring(L, str.c_str().) 20161030 00:57:02< tad_carlucci> celticminstrel, That's where I'd do it. The choice is loading the cleartext source or a binary library. But doing it when we add the string, aux, etc., libraries makes the most sense. 20161030 00:57:55< celticminstrel> I feel like I missed something there. 20161030 00:58:13< celticminstrel> I'm not sure what "that" and "it" refer back to in the first sentence. 20161030 00:59:58< tad_carlucci> Insert lua load above this line: https://github.com/wesnoth/wesnoth/blob/master/src/scripting/lua_kernel_base.cpp#L319 20161030 01:00:57< gfgtdf> celticminstrel: well for most of those string we can assume that they dont contains null chracters, for example in unit type ids ony some chractes are allowed, also user-visible strings shoudln't contin null chracters becaue tey cnnot be displayed 20161030 01:01:37< gfgtdf> celticminstrel: note that even if str contains a null chracters all that happens is that not the full string wil be given to lua, its not liek wesnoth crashes in that case. 20161030 01:01:39< tad_carlucci> I would agree. If we always use C strings even in Lua we're "safe enough" 20161030 01:03:03< tad_carlucci> celticminstrel, Actually, on general principle alone, I'd suggest telling Lua to load a master Wesnoth Lua source at that point. Even if that file is empty, it's a good idea for the future 20161030 01:03:27< celticminstrel> gfgtdf: True, it won't crash, but it's still undesirable behaviour. 20161030 01:03:59< tad_carlucci> celticminstrel, Only undesirable if you appended something after the nul terminator for the unit id or name or whatever. 20161030 01:04:06< celticminstrel> Though you're also right that strings containing nulls should probably be rare in the first place, so not really high priority. 20161030 01:04:23< DeFender1031> is there no way to work with binary data strings in lua that may contain null bytes? 20161030 01:04:38< DeFender1031> (yes, i know i said sleep... damn insomnia again.) 20161030 01:04:51< tad_carlucci> DeFender1031, Lua handles it fine. You just can't think like a C programmer. 20161030 01:04:54< celticminstrel> tad_carlucci: So basically you're saying we should hard-code the load of a specific Lua source file into the C++ code? 20161030 01:05:00< gfgtdf> celticminstrel: well having null cracters in most strign isnt really desiable, even if the strign is not user-visible by default its likeley that it'll break benug views where those strings are still shown. 20161030 01:05:03< celticminstrel> DeFender1031: You should be able to use strings for that. 20161030 01:05:04< tad_carlucci> celticminstrel, Yes. 20161030 01:05:10< DeFender1031> tad_carlucci, not sure i follow. 20161030 01:05:13< celticminstrel> gfgtdf: Uhh, you shouldn't say that. 20161030 01:05:28< gfgtdf> s/benug/debug 20161030 01:05:51< celticminstrel> Okay, the debug views should obviously handle it properly. 20161030 01:06:11< tad_carlucci> DeFender1031, The nul terminator is a C thing. If you came from old Pascal, you're used to lstrings .. strings with length which are 8-bit clean .. 20161030 01:06:27< celticminstrel> And there are probably some good reasons to have nulls in strings. 20161030 01:06:28< celticminstrel> tad_carlucci: I think of those as pstrings. 20161030 01:06:28< DeFender1031> oh, i misread. I thouhgt you guys were saying that lua DOES use null terminators 20161030 01:06:37< DeFender1031> yes, i know nulls are a C thing. 20161030 01:06:43< celticminstrel> Maybe partly because the C syntax for them is p"..." 20161030 01:06:48< celticminstrel> (Nonstandard of course) 20161030 01:06:53< celticminstrel> (Maybe not really supported anymore) 20161030 01:07:21< tad_carlucci> celticminstrel, Back in the 70s the Pascal data type was "lstring" and I'm too old to change now :P 20161030 01:07:25< DeFender1031> and the inconsistency of C sometimes using nulls and sometimes using an explicit length has led to a lot of buffer overflow bugs in the history of the world. 20161030 01:07:26< celticminstrel> Oh right, it was "\p...", sorry. 20161030 01:08:03< celticminstrel> DeFender1031: Well, C is generally pretty consistent about using null when working with strings though... 20161030 01:08:53< DeFender1031> celticminstrel, except when dealing with allocated space. 20161030 01:09:01< DeFender1031> which you need for dynamic strings 20161030 01:09:10< DeFender1031> and let's not forget gets(). 20161030 01:09:16< tad_carlucci> DeFender1031, The issue with overruns comes from strcpy and it's relatives merrily running on because someone forgot to check length beforehand. 20161030 01:09:19< DeFender1031> and strcat. 20161030 01:09:30< DeFender1031> tad_carlucci, exactly my point 20161030 01:10:24< tad_carlucci> C++ says, "Are you SURE you want to shoot THAT foot?" ... C says, "Feet? We don't need no stinkin' feet!" 20161030 01:12:54< vultraz> down with c! 20161030 01:13:37< tad_carlucci> Move on. Use D. Or E, Or F. Or go CLR and use F#. 20161030 01:14:26< vultraz> too lazy! 20161030 01:14:36< vultraz> ill stick to c++ :P 20161030 01:16:18< tad_carlucci> Let's hear it for feature bloat! "This language sucks, Haskel is WAY better!" "Oh, yeah, give the committee a decade and we'll add it to the libraries. Just don't complain about a 300-line error message when you said and meant ." 20161030 01:17:36< vultraz> what exactly does that apply to :P 20161030 01:18:27< tad_carlucci> Oh, I was playing with boost::lexical_cast and boost::numeric_cast earlier today ... 20161030 01:31:02< vultraz> curses upon those who write T const &val :| 20161030 01:31:06-!- ToBeCloud [uid51591@wikimedia/ToBeFree] has quit [Quit: Connection closed for inactivity] 20161030 01:38:09< vultraz> I should add that to Coding Standards 20161030 01:58:08< vultraz> over 100 cases of this abomination! 20161030 01:59:52< DeFender1031> pretty sure that's there already 20161030 02:00:38< DeFender1031> https://wiki.wesnoth.org/CodingStandards#Avoid_implicit_conversions is similar 20161030 02:04:08-!- RatArmy [~RatArmy@om126237116055.9.openmobile.ne.jp] has joined #wesnoth-dev 20161030 02:04:42< vultraz> nah, this is a formatting thing 20161030 02:04:49< vultraz> const qualifier after type instead of before 20161030 02:04:53< vultraz> in an argument 20161030 02:07:58< DeFender1031> oh, that's what you meant. 20161030 02:08:40< DeFender1031> i thought you were referring to the long strings of template errors that tad_carlucci was talking about which often result from disorganized template usage. 20161030 02:11:29< tad_carlucci> stackoverflow.com/questions/2640446/why-do-some-people-prefer-t-const-over-const-t 20161030 02:12:50< tad_carlucci> I would point out that if T is a preprocessing token it would lead to some surprising mistakes. 20161030 02:13:25< tad_carlucci> #define T (void) // Have fun!!! 20161030 02:17:05-!- gfgtdf_ [~chatzilla@x4e32b47a.dyn.telefonica.de] has joined #wesnoth-dev 20161030 02:18:55-!- gfgtdf [~chatzilla@x50ab6fb9.dyn.telefonica.de] has quit [Ping timeout: 252 seconds] 20161030 02:19:00-!- gfgtdf_ is now known as gfgtdf 20161030 02:31:20-!- RatArmy [~RatArmy@om126237116055.9.openmobile.ne.jp] has quit [Ping timeout: 265 seconds] 20161030 02:35:55-!- gfgtdf [~chatzilla@x4e32b47a.dyn.telefonica.de] has quit [Quit: ChatZilla 0.9.92 [Firefox 49.0.2/20161019084923]] 20161030 02:37:31< celticminstrel> tad_carlucci: Any reason why you tend to leave off the http from your links? 20161030 02:38:03< tad_carlucci> Ask Chromodo/Chrome I drag from the bar to here. 20161030 02:38:47< celticminstrel> Ah... 20161030 02:39:18< tad_carlucci> Chromium 20161030 02:40:25< tad_carlucci> There's probably an options somewhere for that. Or I could figure out why copy/paste doesn't work from Chromium like it does everywhere else. But I've learned to live with things like they are so .. shrug. 20161030 02:40:49< celticminstrel> I dunno, is Chromium as option-starved as Chrome? 20161030 02:41:06< vultraz> copypaste from chrome's url bar works fine 20161030 02:41:08< vultraz> for me 20161030 02:41:17< celticminstrel> You're on Windows, so your testimony doesn't count. 20161030 02:41:21< vultraz> :P 20161030 02:42:07< tad_carlucci> Get a real OS. Something BSD-ish instead of some hacked up version of CP/M 20161030 02:42:08-!- stikonas [~gentoo@wesnoth/translator/stikonas] has quit [Quit: Konversation terminated!] 20161030 02:42:20< celticminstrel> Something BSD-ish? Like Mac OSX? 20161030 02:42:59< tad_carlucci> Or Linux. It's close enough I've never had much issues using old BSD stuff on it. 20161030 02:43:35< vultraz> I can;'t stand working on linux 20161030 02:43:36< vultraz> tbh 20161030 02:43:42-!- stikonas [~gentoo@wesnoth/translator/stikonas] has joined #wesnoth-dev 20161030 02:43:49< vultraz> though granted i haven't in years, it's just such a different type of ecosystem 20161030 02:45:11< tad_carlucci> Fire up a VM with Ubuntu/Mint sometime. I think there's a desktop theme comes with it which look just like Windows 10 except no live tiles on the Start menu .. which one could argue is A Good Thing(sm). 20161030 02:46:15< vultraz> pfft 20161030 02:46:21< vultraz> i love live tiles 20161030 02:47:20< tad_carlucci> I love my empty black desktop. 20161030 02:56:17< DeFender1031> i'm on linux. I use chrome. It includes the protocol when I copy paste. 20161030 02:57:42< tad_carlucci> DeFender1031, So does mine if I middle-click/paste it. But sometimes I forget that and drag it and then it doesn't. 20161030 02:58:24< DeFender1031> ah 20161030 02:58:31< DeFender1031> i rarely drag 20161030 02:59:34< tad_carlucci> Somewhere is a howto to get it all working but it's too much hassle. So I live with it as it is. I'm usually in vi anyway :P 20161030 03:01:44< tad_carlucci> I remember when X11 came out for Linux. I was like, "So? All that work to do what I've been doing all along on a virtual tty?" But I have to admit, http: is better than gopher: so graphics does have some use. 20161030 03:06:44< tad_carlucci> I was thinking, earlier today, about firing up the Solaris box and seeing what it would take to get Wesnoth running on it. But, then, I thought .. Solaris? Who uses THAT any more? At which point I woke and realized I'd been dreaming. 20161030 03:17:47< DeFender1031> tad_carlucci, I take it you're an old-school techie from the first age. 20161030 03:19:07< tad_carlucci> DeFender1031, Yea, I guess. Dunno about "first age" .. never used a vacuum tube system .. but I've been at it a while. 20161030 03:21:43< tad_carlucci> https://en.wikipedia.org/wiki/IBM_1401#/media/File:BRL61-IBM_1401.jpg 20161030 03:22:13< tad_carlucci> Pic of first system I every got PAID to use. 20161030 03:24:36< DeFender1031> second age then. 20161030 03:24:42< DeFender1031> :P 20161030 03:25:15< DeFender1031> sigh... vultraz is right, we DO need more lore. 20161030 03:25:47-!- stikonas [~gentoo@wesnoth/translator/stikonas] has quit [Quit: Konversation terminated!] 20161030 03:25:52< DeFender1031> the only references I can think to make about the ages are tolkienish, not wesnothian. 20161030 03:27:09< tad_carlucci> There's several pages on the Wiki which cover Wesnoth history. 20161030 03:27:23< DeFender1031> i know 20161030 03:28:08< tad_carlucci> I agree, though, it would be good if there were more verbage tying it all into a consistent narrative. 20161030 03:33:11-!- RatArmy [~RatArmy@om126237116055.9.openmobile.ne.jp] has joined #wesnoth-dev 20161030 04:03:25-!- RatArmy [~RatArmy@om126237116055.9.openmobile.ne.jp] has quit [Ping timeout: 260 seconds] 20161030 04:06:21-!- vultraz [~chatzilla@wesnoth/developer/vultraz] has quit [Ping timeout: 250 seconds] 20161030 04:31:43-!- bumbadadabum [~bumbadada@wesnoth/developer/bumbadadabum] has quit [Ping timeout: 245 seconds] 20161030 04:42:27-!- bumbadadabum [~bumbadada@wesnoth/developer/bumbadadabum] has joined #wesnoth-dev 20161030 05:34:11-!- tad_carlucci [~lundberg@173.217.65.103] has quit [Quit: Off to resolve a merge conflict between the wife and husband branches of my real life.] 20161030 06:09:18-!- Kwandulin [~Miranda@p5DDD2B8F.dip0.t-ipconnect.de] has joined #wesnoth-dev 20161030 06:15:46-!- JyrkiVesterinen [~JyrkiVest@87-100-241-161.bb.dnainternet.fi] has joined #wesnoth-dev 20161030 07:12:10-!- celticminstrel [~celmin@unaffiliated/celticminstrel] has quit [Quit: And lo! The computer falls into a deep sleep, to awake again some other day!] 20161030 08:17:09-!- zookeeper [~lmsnie@wesnoth/developer/zookeeper] has joined #wesnoth-dev 20161030 08:36:43-!- Kwandulin [~Miranda@p5DDD2B8F.dip0.t-ipconnect.de] has quit [Ping timeout: 245 seconds] 20161030 08:38:51-!- ChipmunkV [~vova@static-89-94-113-91.axione.abo.bbox.fr] has joined #wesnoth-dev 20161030 08:40:22-!- mjs-de [~mjs-de@p508C8204.dip0.t-ipconnect.de] has joined #wesnoth-dev 20161030 08:50:41-!- vultraz [~chatzilla@wesnoth/developer/vultraz] has joined #wesnoth-dev 20161030 08:52:14-!- wedge009 [~Thunderbi@60-241-236-92.static.tpgi.com.au] has joined #wesnoth-dev 20161030 08:53:38-!- horrowind [~Icedove@2a02:810a:8380:10a8:21b:fcff:fee3:c3ff] has joined #wesnoth-dev 20161030 08:58:48-!- irker698 [~irker@uruz.ai0867.net] has joined #wesnoth-dev 20161030 08:58:48< irker698> wesnoth: Charles Dang wesnoth:master 6e021ba7465b / src/serialization/ (string_utils.cpp string_utils.hpp): String Utils: formatting and documentation cleanup https://github.com/wesnoth/wesnoth/commit/6e021ba7465b51eaf46090d4317657cc3e06f3f8 20161030 08:59:08-!- Kwandulin [~Miranda@p5DDD2B8F.dip0.t-ipconnect.de] has joined #wesnoth-dev 20161030 09:01:12< vultraz> DeFender1031: ^ cleaned up the docs for the *_split stuff a little so it's easier to read 20161030 09:05:28-!- Kwandulin [~Miranda@p5DDD2B8F.dip0.t-ipconnect.de] has quit [Ping timeout: 260 seconds] 20161030 09:23:43-!- Kwandulin [~Miranda@p5DDD2B8F.dip0.t-ipconnect.de] has joined #wesnoth-dev 20161030 09:30:52-!- Kwandulin [~Miranda@p5DDD2B8F.dip0.t-ipconnect.de] has quit [Ping timeout: 252 seconds] 20161030 09:50:57-!- blackspirit [~blackspir@adsl-128.37.6.49.tellas.gr] has joined #wesnoth-dev 20161030 09:54:16-!- wedge009 [~Thunderbi@60-241-236-92.static.tpgi.com.au] has quit [Quit: wedge009] 20161030 09:54:34-!- wedge009 [~Thunderbi@60-241-236-92.static.tpgi.com.au] has joined #wesnoth-dev 20161030 09:56:35-!- wedge010 [~Thunderbi@60-241-236-92.static.tpgi.com.au] has joined #wesnoth-dev 20161030 09:59:01-!- wedge009 [~Thunderbi@60-241-236-92.static.tpgi.com.au] has quit [Ping timeout: 260 seconds] 20161030 09:59:01-!- wedge010 is now known as wedge009 20161030 10:03:54-!- JyrkiVesterinen [~JyrkiVest@87-100-241-161.bb.dnainternet.fi] has quit [Remote host closed the connection] 20161030 10:45:03-!- Kwandulin [~Miranda@p5DDD2B8F.dip0.t-ipconnect.de] has joined #wesnoth-dev 20161030 10:59:54-!- blackspirit [~blackspir@adsl-128.37.6.49.tellas.gr] has quit [Quit: Leaving] 20161030 11:05:31-!- louis94 [~~louis94@91.178.241.241] has joined #wesnoth-dev 20161030 11:05:52-!- wedge009 [~Thunderbi@60-241-236-92.static.tpgi.com.au] has quit [Quit: wedge009] 20161030 11:06:10-!- wedge009 [~Thunderbi@60-241-236-92.static.tpgi.com.au] has joined #wesnoth-dev 20161030 11:08:24-!- wedge009 [~Thunderbi@60-241-236-92.static.tpgi.com.au] has quit [Client Quit] 20161030 11:09:00-!- wedge009 [~Thunderbi@60-241-236-92.static.tpgi.com.au] has joined #wesnoth-dev 20161030 11:09:39-!- wedge009 [~Thunderbi@60-241-236-92.static.tpgi.com.au] has quit [Client Quit] 20161030 11:11:26-!- wedge009 [~Thunderbi@60-241-236-92.static.tpgi.com.au] has joined #wesnoth-dev 20161030 11:11:37-!- wedge009 [~Thunderbi@60-241-236-92.static.tpgi.com.au] has quit [Client Quit] 20161030 11:20:03-!- wedge009 [~Thunderbi@60-241-236-92.static.tpgi.com.au] has joined #wesnoth-dev 20161030 11:59:00-!- irker698 [~irker@uruz.ai0867.net] has quit [Quit: transmission timeout] 20161030 12:01:54-!- louis94 [~~louis94@91.178.241.241] has quit [Ping timeout: 256 seconds] 20161030 12:08:45-!- Kwandulin [~Miranda@p5DDD2B8F.dip0.t-ipconnect.de] has quit [Ping timeout: 260 seconds] 20161030 12:27:35-!- louis94 [~~louis94@91.178.241.241] has joined #wesnoth-dev 20161030 13:09:24-!- stikonas [~gentoo@wesnoth/translator/stikonas] has joined #wesnoth-dev 20161030 13:21:12< DeFender1031> vultraz, cool. I see you killed off a bunch of that const-after-type syntax that we all hate. 20161030 13:21:24< vultraz> indeed 20161030 13:21:39< DeFender1031> vultraz, looks like my first step is going to be to determine what the current behavior of these functions is 20161030 13:21:44< shadowm> We do? 20161030 13:21:55< vultraz> We do 20161030 13:22:10< shadowm> Really? 20161030 13:22:10< DeFender1031> shadowm, yes. we do. There was probably a vote and stuff. 20161030 13:22:14< DeFender1031> :P 20161030 13:22:18< vultraz> :P 20161030 13:25:31< DeFender1031> Anyway, my first task would seem to be to determine the current behavior of the functions, particularly in edge cases, and possibly discuss whether those are the correct behaviors. 20161030 13:26:08< DeFender1031> for example, in the square bracket syntax, if there are multiple sets of brackets, they must each expand to the same number of entries. But what happens if they don't? How does the function handle that? 20161030 13:27:53< DeFender1031> anyway, I also have day job work that i must make some progress on today. 20161030 13:32:02-!- JyrkiVesterinen [~JyrkiVest@87-100-193-146.bb.dnainternet.fi] has joined #wesnoth-dev 20161030 13:32:29< vultraz> yay for unnamed function arguments in headers :| 20161030 13:33:04-!- tad_carlucci [~lundberg@173.217.65.103] has joined #wesnoth-dev 20161030 13:34:28< DeFender1031> vultraz, arguments don't need names in forward declarations... you only need a name if you plan to work with the variable. What's that? Self-documenting headers? Pffff. Who needs to know what functions do at a glance anyway? 20161030 13:38:20< vultraz> Because i totally don't want to know what a random string argument means, right? :P 20161030 13:39:35< DeFender1031> Nah, you just figure it out through trial and error, obviously. 20161030 13:46:56< zookeeper> castles<->walls: https://dl.dropboxusercontent.com/u/63964618/wesnoth/castletocavewallprogress3.jpg 20161030 13:47:01< zookeeper> i feel slightly like a wizard 20161030 13:48:09< vultraz> zookeeper: but does it work with stone walls, that is the question 20161030 13:48:45< zookeeper> if the layering problems with it can be fixed, then yes i think so 20161030 13:49:42< vultraz> ah 20161030 13:49:52< vultraz> perhaps you should tell doofus 20161030 13:50:12< tad_carlucci> Bah. Keep it short. 'a' 'b' 'c' ... and if you get to 'z' refactor into 'f1' 'f2' ... 20161030 13:50:13< zookeeper> no 20161030 13:50:48< zookeeper> the stone walls have some problems of their own btw 20161030 13:51:03< zookeeper> in fact they're very screwy 20161030 13:51:18< vultraz> is that no to me or tad 20161030 13:51:33< tad_carlucci> I'll take it. 20161030 13:51:49< zookeeper> vultraz 20161030 13:52:18< vultraz> well, he seems to be working on castle-> wall transitions 20161030 13:52:25< zookeeper> obviously 20161030 13:52:30< vultraz> and i think your wml solution would probably be used instead 20161030 13:52:40< vultraz> so perhaps not waste his effort? 20161030 13:53:08< zookeeper> oh i thought you mean tell him about the layering problems 20161030 13:53:42< vultraz> nah, just point out you have a better solution incoming 20161030 13:53:48< zookeeper> sure 20161030 14:04:52-!- irker858 [~irker@uruz.ai0867.net] has joined #wesnoth-dev 20161030 14:04:52< irker858> wesnoth: Charles Dang wesnoth:master 8c92a9ee8e57 / src/ (45 files in 17 dirs): Formatting cleanup: moved const qualifiers before type names https://github.com/wesnoth/wesnoth/commit/8c92a9ee8e5725c16ec659d1bacd868aa2922c28 20161030 14:05:19< vultraz> annnd there's (hopefully) the rest 20161030 14:15:40-!- Kwandulin [~Miranda@p5DDD2B8F.dip0.t-ipconnect.de] has joined #wesnoth-dev 20161030 14:21:43< zookeeper> urgh... of course, keeps are quite a problem. 20161030 14:32:19< zookeeper> or maybe not. 20161030 14:33:00< zookeeper> oh yeah i think this will work. 20161030 14:40:00-!- JyrkiVesterinen [~JyrkiVest@87-100-193-146.bb.dnainternet.fi] has quit [Remote host closed the connection] 20161030 14:54:30< irker858> wesnoth: Gregory A Lundberg wesnoth:master fb715ec5182b / SConstruct: SCons Fix bug: Git Hash https://github.com/wesnoth/wesnoth/commit/fb715ec5182b474f739c009c09090ecfb5bc4cec 20161030 14:54:32< irker858> wesnoth: Charles Dang wesnoth:master 1627422abfb6 / SConstruct: Merge pull request #849 from GregoryLundberg/GL_SCons_git_hash https://github.com/wesnoth/wesnoth/commit/1627422abfb61eee8c9d7cf7dba46191fbd4c786 20161030 15:01:06-!- celticminstrel [~celmin@unaffiliated/celticminstrel] has joined #wesnoth-dev 20161030 15:20:37< celticminstrel> vultraz: Why did you break the documentation in string utils. 20161030 15:20:46< vultraz> ? 20161030 15:20:57< celticminstrel> Lines 39 and 40. You removed the < 20161030 15:21:36< celticminstrel> So now the documentation about REMOVE_EMPTY is actually linked to STRIP_SPACES. 20161030 15:22:09< celticminstrel> (I also seriously question the decision to switch from /// to /**, but whatever. They are equivalent after all.) 20161030 15:22:36< tad_carlucci> Just so the style is consistent so one can grep for it. 20161030 15:22:43< celticminstrel> (Actually for the enums I think ///< is quite appropriate though...) 20161030 15:22:56< celticminstrel> tad_carlucci: You can grep for it even if it's not consistent. 20161030 15:23:16< vultraz> ...what? 20161030 15:23:20< celticminstrel> Because it's just two simple patterns. 20161030 15:23:23< tad_carlucci> celticminstrel, of course but why make it harder than it need be? 20161030 15:23:28< vultraz> REMOVE_EMPTY = 0x01, /** REMOVE_EMPTY: remove empty elements. */ 20161030 15:23:31< vultraz> how is this broken :| 20161030 15:23:52< celticminstrel> It's broken because a /** */ comment always applies to the source element that comes after it. 20161030 15:23:58< celticminstrel> Go google Doxygen. 20161030 15:25:48< celticminstrel> By the rules of doxygen comments, that comment describing REMOVE_EMPTY goes with the symbol STRIP_SPACES. 20161030 15:27:33 * vultraz mutters darkly 20161030 15:29:12< celticminstrel> What's wrong now. 20161030 15:29:15-!- Kwandulin [~Miranda@p5DDD2B8F.dip0.t-ipconnect.de] has quit [Read error: Connection reset by peer] 20161030 15:30:16< vultraz> gonna be a large rebuild if i fix it 20161030 15:30:33< celticminstrel> Ah, well, you should've thought of that before you broke it, 20161030 15:31:36< celticminstrel> I think that's the only actual problem with that commit, at least. 20161030 15:32:09< celticminstrel> But why did you remove it in the first place? You should've known there must be a reason for it to be there... 20161030 15:33:56< vultraz> I don't like how it looks 20161030 15:34:14< celticminstrel> That's not a very good reason. 20161030 15:34:27< celticminstrel> But, does ///< look any better? 20161030 15:34:56< celticminstrel> It's not quite equivalent, but it's close enough. 20161030 15:35:10< vultraz> no, /// doesn't look good at all 20161030 15:35:26< celticminstrel> The other alternatives are /*!< and //~< 20161030 15:35:30< celticminstrel> Sorry, //!< 20161030 15:35:41< celticminstrel> But really, I think you're being silly. 20161030 15:37:00< celticminstrel> Personally I think ///< would actually be better there. 20161030 15:37:15< celticminstrel> (Or //!<, but I don't like the exclamation mark form.) 20161030 15:37:55< vultraz> personally don't like comments after things at all 20161030 15:37:57< vultraz> they should be on top 20161030 15:40:57< tad_carlucci> Personally, I prefer a large comment block I can collapse and ignore because it's usually either wrong or redundant. 20161030 15:41:55< celticminstrel> Well, I usually prefer them on top too. 20161030 15:42:02< celticminstrel> But I make an exception for enum constants. 20161030 15:42:17< celticminstrel> Still, if you really wanted, you could put the comments before the constants. 20161030 15:42:24< celticminstrel> On a line of their own. 20161030 15:51:40< tad_carlucci> Geez. that const change might as well have been 'make all' 20161030 15:56:18< celticminstrel> So what's up with this flg issue? 20161030 15:56:24< celticminstrel> When can we do 1.13.6? 20161030 15:56:29< celticminstrel> I want to do the rename already. 20161030 15:56:42 * vultraz groans 20161030 15:57:39< celticminstrel> I wonder if mattsc has the file dialog crash. 20161030 15:58:07< tad_carlucci> I'm running debug and release builds on Linux and Windows to check everything is clean. Can't to OS/X to check it there. 20161030 16:09:17-!- Kwandulin [~Miranda@p5DDD2B8F.dip0.t-ipconnect.de] has joined #wesnoth-dev 20161030 16:58:19-!- gfgtdf [~chatzilla@x4e32b47a.dyn.telefonica.de] has joined #wesnoth-dev 20161030 17:01:22< vultraz> I think I have an idea for a workaround for the flg thing 20161030 17:06:18< gfgtdf> vultraz: so what is your plan ? 20161030 17:07:17< vultraz> move that code to a separate function and call it outside the class where the object is instantiated before calling show 20161030 17:07:37< gfgtdf> vultraz: ok 20161030 17:17:20< gfgtdf> vultraz: about the enums, you can also just put the comment before the enum values liek tis for example done here: https://github.com/wesnoth/wesnoth/blob/master/src/addon/state.hpp#L23 20161030 17:30:15< celticminstrel> I already mentioned that, for the record. 20161030 17:31:38< gfgtdf> celticminstrel: ok 20161030 17:32:29-!- mjs-de [~mjs-de@p508C8204.dip0.t-ipconnect.de] has quit [Remote host closed the connection] 20161030 17:42:03-!- Kwandulin [~Miranda@p5DDD2B8F.dip0.t-ipconnect.de] has quit [Read error: Connection reset by peer] 20161030 17:45:46-!- louis94 [~~louis94@91.178.241.241] has quit [Ping timeout: 250 seconds] 20161030 19:06:34< celticminstrel> Oh, gfgtdf was reviewing it too, huh. 20161030 19:07:01< celticminstrel> But it seems like only one of your comments was duplicated by me. 20161030 19:07:17< celticminstrel> Wait, two, sorry. 20161030 19:07:28< celticminstrel> #1 and #4 20161030 19:08:20< celticminstrel> I don't like how the luaW_* functions follow a different idiom from the lua_* functions, by the way. 20161030 19:09:18< celticminstrel> I wonder if it's worth fixing though. 20161030 19:09:22< tad_carlucci> What does that mean? 20161030 19:12:57< celticminstrel> tad_carlucci: For built-in Lua types you have "lua_toT(L, n) ->T" and "luaL_checkT(L, n) -> T". For translatable strings, it's "luaW_totstring(L, n, tstr_ref) -> bool". Configs and some others also follow that. Some wesnoth types do stick to the normal idiom though. 20161030 19:13:21< celticminstrel> The check version is generally the same in both cases. 20161030 19:13:56< tad_carlucci> Ah. 20161030 19:38:07< irker858> wesnoth: Charles Dang wesnoth:master d9f1ee87a872 / src/ (3 files in 2 dirs): MP Join Game: workaround for Faction Select dialog not showing https://github.com/wesnoth/wesnoth/commit/d9f1ee87a872e65ead8018a9cb242a493ea4de1c 20161030 19:38:10< vultraz> gfgtdf: ^ 20161030 19:39:14< gfgtdf> vultraz: you tested that it works ? 20161030 19:39:19< vultraz> yes 20161030 19:39:24< gfgtdf> vultraz: bice :D 20161030 19:39:27< vultraz> I don't like it, but it works 20161030 19:39:29< gfgtdf> nice* 20161030 19:39:41< gfgtdf> vultraz: are trhere more blockers for 1.13.6 rlease ? 20161030 19:39:49< vultraz> i don't think so 20161030 19:40:07< zookeeper> release early next week? 20161030 19:40:56< vultraz> it IS early next week :| 20161030 19:41:01< vultraz> it's monday morning 20161030 19:41:05< zookeeper> nah 20161030 19:41:10< tad_carlucci> Are the crashes resizing the window on the list? 20161030 20:14:50-!- TheJJ [~rofl@ipbcc36896.dynamic.kabel-deutschland.de] has quit [Ping timeout: 250 seconds] 20161030 20:19:24-!- TheJJ [~rofl@ipbcc36896.dynamic.kabel-deutschland.de] has joined #wesnoth-dev 20161030 20:30:32-!- wedge009 [~Thunderbi@60-241-236-92.static.tpgi.com.au] has quit [Ping timeout: 260 seconds] 20161030 20:44:25-!- Appleman1234 [~Appleman1@KD036012042213.au-net.ne.jp] has quit [Ping timeout: 260 seconds] 20161030 20:52:36< Aginor> tad_carlucci: what crashes? 20161030 20:53:44< tad_carlucci> Pick one. Startup, resize to smaller than 800x600. In game, [message] up, resize smaller (sometimes). Those are the two I've seen today and remember. 20161030 20:54:07< tad_carlucci> I get a message about wanted/expected/got and a coredump 20161030 20:54:15< Aginor> hmm 20161030 20:54:25< Aginor> that sounds like the asserts in gui2 kicking in 20161030 20:54:27< vultraz> 800x600 is the min 20161030 20:54:32< vultraz> how do you even get it smaller 20161030 20:54:52< tad_carlucci> Drag the corner. 20161030 20:55:22< tad_carlucci> Also, Aginor, when [message] is up repaints are missed and layout goes wrong. 20161030 20:55:25< vultraz> not possible 20161030 20:55:32< vultraz> the window will not go smaller 20161030 20:55:38< vultraz> you obviously have some weird window manager :P 20161030 20:55:55< tad_carlucci> vultraz, Sure it will. I run LXDE like a lot of ppl. 20161030 20:56:07< vultraz> (Windows 10, remember?) 20161030 20:56:14< Aginor> I think it's a WM issue :/ 20161030 20:56:28< Aginor> not respecting the minimum ize the application requests 20161030 20:59:28< shadowm> SDL 1.2 didn't set a minimum size hint and it was possible to make the Wesnoth window smaller than 800x480, although the game would carry on pretending it was actually 800x480 and then begin glitching input events horribly until restarted. 20161030 20:59:35< tad_carlucci> OK. Windows 10 won't drag smaller. So 20161030 20:59:46< shadowm> (On X11.) 20161030 21:00:04< shadowm> AFAICT SDL 2.0.4 sets the correct hint on X11. 20161030 21:00:26< shadowm> And my window manager honors it as it should. 20161030 21:00:30< DeFender1031> wouldn't the window manager just provide scrollbars to the game and continue to run everything as normal? 20161030 21:01:03< shadowm> Window managers generally don't provide anything that involves drawing into the client area, no. 20161030 21:04:07< tad_carlucci> Windows 10 resizing during startup for HttT crashes back to titlescreen (seen that too on Linux). no messages. 20161030 21:06:18-!- Shiki [~Shiki@141.39.226.226] has joined #wesnoth-dev 20161030 21:06:39< vultraz> confirmed the back to titlescreen thing 20161030 21:07:28< tad_carlucci> Windows 10 resizing with [message] up .. keep retrying .. layout and paints wrong/missing 20161030 21:08:37< tad_carlucci> I fast-moved Konrad to the goal for S01 on the last test but I noted it when checking the [message][option] lag last week. 20161030 21:10:52< tad_carlucci> Linux you are correct the window won't size smaller. But it does not layout/paint all the time if you can resize while it's starting up (needed to be fast or add CPU load to test it). 20161030 21:11:19< tad_carlucci> So it's not that it gets the 600x size it's that it thinkgs it should and 800x600 was what it was given. 20161030 21:12:13< irker858> wesnoth: Charles Dang wesnoth:master 2db29bb02c70 / src/gui/dialogs/drop_down_list.hpp: Drop Down List: set restore flag https://github.com/wesnoth/wesnoth/commit/2db29bb02c70068dffed37859dbc989868f3c1a1 20161030 21:16:18< Aginor> 10:04 < tad_carlucci> Windows 10 resizing during startup for HttT crashes back to titlescreen (seen that too on Linux). no messages. 20161030 21:16:35< Aginor> ^ that's a threading issue, I think there's an open bug for it 20161030 21:16:54< vultraz> tad_carlucci: resizing during a message results in bad drawing on the map, confirmed, but it seems to resolve next message 20161030 21:17:22< tad_carlucci> Sometimes just clicking on the map fixes it. 20161030 21:18:00< tad_carlucci> The question today is should these be blockers for 1.13.6? I vote not but that's up to you two. 20161030 21:18:20< vultraz> the [message] thing, certainly not 20161030 21:18:31< vultraz> the threading issue is slightly more serious but I'd still say not 20161030 21:19:07< tad_carlucci> The resize on start is a race .. can you do it before the titlescreen appears? If not, you won't see the problem. It takes speed or very high load. 20161030 21:19:40< vultraz> i likely cannot 20161030 21:19:53< tad_carlucci> So, these are issues which need attention for 1.13.6+dev 20161030 21:20:29< tad_carlucci> vultraz, I used 'speed' put the mouse at the corned, used the keyboard to kill and restart and dragged as soon as I could. But it's hard even then 20161030 21:20:54< tad_carlucci> Load is easy .. fire off a build all and test whike it's running :P 20161030 21:20:56< vultraz> if it's so hard, it's obviously a corner case :| 20161030 21:21:04< vultraz> (literally :P ) 20161030 21:21:29< tad_carlucci> Most users won't be compiling a million lines of code while playing, though. 20161030 21:21:47< vultraz> millions? 20161030 21:22:04< tad_carlucci> Never counted Wesnoth. "Big enough" is all I say. 20161030 21:23:04< tad_carlucci> Of course, right now, I have 4 compiles running in parallel getting that dropdown change in before I check the fade-to-black thing in MP. 20161030 21:23:27< vultraz> o_O 20161030 21:25:04< DeFender1031> is wesnoth that slow to compile? 20161030 21:25:42< tad_carlucci> DeFender1031, Sure, if you're doing Release and Debug on Linux and Visual Studio all at the same time :P 20161030 21:27:52< matthiaskrgr> try -fsanitize=address,undefined -g3 20161030 21:28:01< matthiaskrgr> you will end up with 5.1G build directory :P 20161030 21:28:33< tad_carlucci> I have enough linking -O0 with debug symbols, thank you. 20161030 21:29:02< matthiaskrgr> :D 20161030 21:29:25< DeFender1031> tad_carlucci, that's... beautiful. 20161030 21:33:34< tad_carlucci> As for speed both Linux runs finished and Visual Studio's still chuggin' 20161030 21:39:32< gfgtdf> Aginor: do you hav a stacktrace or similar for the loadingscreen bug ? 20161030 21:40:45-!- Appleman1234 [~Appleman1@KD036012032169.au-net.ne.jp] has joined #wesnoth-dev 20161030 21:42:33< tad_carlucci> mp_join_game.cpp(190) warning as error unreachable code. 20161030 21:43:45-!- horrowind [~Icedove@2a02:810a:8380:10a8:21b:fcff:fee3:c3ff] has quit [Remote host closed the connection] 20161030 21:43:58< tad_carlucci> Yep return false; throw. 20161030 21:44:15-!- horrowind [~Icedove@2a02:810a:8380:10a8:21b:fcff:fee3:c3ff] has joined #wesnoth-dev 20161030 21:44:22< tad_carlucci> So which should go? the return or the throw? 20161030 21:44:40< gfgtdf> vultraz: ^ 20161030 21:44:55< shadowm> Easiest way to tell would be to use git blame or git log -p or whatever to see who introduced the unreachable code and ask them. 20161030 21:45:00< vultraz> throw i guess 20161030 21:45:06< vultraz> it was me 20161030 21:45:11< vultraz> it threw in the gui1 code 20161030 21:45:18-!- horrowind [~Icedove@2a02:810a:8380:10a8:21b:fcff:fee3:c3ff] has quit [Client Quit] 20161030 21:45:26< vultraz> but in the gui2 code i used set retval so i guess technically it never threw 20161030 21:45:43< vultraz> so uh.. 20161030 21:45:48< vultraz> actually maybe make it just return 20161030 21:45:53< tad_carlucci> I think you said it was a temp hack to get 1.13.6 out. I'm commenting out the throw locally to finish the Debug build on Windows. Not gonna commit it 20161030 21:45:54< vultraz> i dont want to have to catch the exception 20161030 21:46:06< gfgtdf> Aginor: i know that the loadgscreen has an issue whare it might crash when you close the game durign the loadscreen, but a crash related to resizing is new to mw 20161030 21:46:51< gfgtdf> me* 20161030 21:46:53< gfgtdf> i wonder whetehr it'd be ok to just call exit() when receiving a quit game from loadingscreen 20161030 21:47:04< tad_carlucci> ACK 20161030 21:47:14-!- esr [~esr@wesnoth/developer/esr] has quit [Quit: WeeChat 1.4] 20161030 21:47:31< tad_carlucci> Sure. IF you don't have any files open, mutex locked shared memory, or any of a number of other things to get messed up 20161030 21:48:54< zookeeper> shadowm, you're rather familiar with the preprocessor innards, right? i'm trying to figure out whether it's feasible to try to add support for optional macro arguments, so if you've at some point concluded that it'd be a fool's errand, now would be a good time to say. 20161030 21:50:05< gfgtdf> zookeeper: what is your suggested syntax to specifyl the sefualt values for those optional parameters? 20161030 21:50:39< celticminstrel> vultraz: What about my inability to load maps in the editor? Is that a blocker? 20161030 21:51:08< celticminstrel> Probably should depend partly on whether mattsc experiences it too. 20161030 21:51:12< celticminstrel> ...or ancestral. 20161030 21:51:20< celticminstrel> Neither of whom are around... 20161030 21:51:27< vultraz> celticminstrel: whaa? 20161030 21:52:00< celticminstrel> I've said it a few times in the past week. The game crashes when I choose Load Map from the File menu. 20161030 21:52:02< tad_carlucci> Is there a map in mainline I can test with? 20161030 21:52:13< zookeeper> gfgtdf, not entirely sure, i'm thinking of #define MYMACRO ARG1 ARG2=(the default value for ARG2, multiple lines allowed by these parentheses) 20161030 21:52:18< celticminstrel> tad_carlucci: You should be able to just load a map from a campaign or MP scenario? 20161030 21:52:20< shadowm> zookeeper: "Familiar" would be overselling it. 20161030 21:52:47< Aginor> gfgtdf: I think I raised it a few months ago 20161030 21:52:50< tad_carlucci> Clicked on "Load map" and goodnightirene 20161030 21:52:59< tad_carlucci> Caught general exception: 20161030 21:52:59< tad_carlucci> boost::filesystem::directory_iterator::construct: Permission denied: "/media" 20161030 21:53:20< celticminstrel> Hmm. Pretty sure that's not the same thing I got, but... maybe the root cause is related... 20161030 21:53:28< Aginor> gfgtdf: if tad_carlucci is able to reproduce it now, we might be able to ask him nicely to upload a stack trace 20161030 21:53:58< tad_carlucci> And now you know why I just build Release and Debug both ... 20161030 21:54:05< gfgtdf> Aginor: searching our bugtracker for entryies submitted by anignor didnt find it 20161030 21:54:23< shadowm> zookeeper: I think basically I never pursued that task because I couldn't decide how to make it useful for multiline default values. 20161030 21:54:38< zookeeper> shadowm, hmh, okay 20161030 21:54:38< shadowm> And something else also involving syntax. 20161030 21:54:39< gfgtdf> tad_carlucci: you ahve a stacktrace from where tehtta exception is thorwn ? 20161030 21:54:49< tad_carlucci> OH COOL! Debug build. "backtrace" --> "No stack" 20161030 21:55:04< tad_carlucci> Let me catch exceptions ... 20161030 21:55:43-!- Shiki [~Shiki@141.39.226.226] has quit [Remote host closed the connection] 20161030 21:59:40< tad_carlucci> http://pastebin.com/LYyabhG3 20161030 22:01:27< gfgtdf> ok it point to this line: https://github.com/wesnoth/wesnoth/blob/master/src/desktop/paths.cpp#L112 20161030 22:01:46< tad_carlucci> $ ls -al / | grep media 20161030 22:01:46< tad_carlucci> drwxr-x--- 4 root root 4096 Jun 24 23:25 media 20161030 22:04:43< gfgtdf> hmm yes we shodul fi that code to not just stip those directores if we dont have access to them 20161030 22:08:21< tad_carlucci> Windows 10 I was able to load AOI S01 map without problems. 20161030 22:08:49< gfgtdf> at first i though this was an erro on the boost side since w euse the is_empty function that takes an erro_code parameter, but a deeper looks shows that the 'is_empty(const path& p, system::error_code& ec)' funcrtion isn't marked as noexcept at all in the boost documentation. 20161030 22:09:54< gfgtdf> if i were to fix it i'd jut wrap those 4 lines in a try{} catch(...) {/*Do nothing*/} block, shodul i commit that or does someone has a better idea ? 20161030 22:10:55< tad_carlucci> However, non-fatal messages on screen when I Load Recent .. "The filename, ... syntax is incorrect." I see "/" and "\" in the pathname .. might be it. 20161030 22:15:27< irker858> wesnoth: gfgtdf wesnoth:master 09d988b144cc / src/desktop/paths.cpp: fix crash in load map dialog when you have no permissions on /media https://github.com/wesnoth/wesnoth/commit/09d988b144cc4d3e3c77dd193aaacd4de0ba1e1e 20161030 22:15:27-!- tad_carlucci [~lundberg@173.217.65.103] has quit [Read error: Connection reset by peer] 20161030 22:15:34-!- tad_carlucci [~lundberg@173.217.65.103] has joined #wesnoth-dev 20161030 22:15:37< gfgtdf> tad_carlucci: try that ^ 20161030 22:16:00< tad_carlucci> I was trying to say it was Window button not Load Recent ... I missed that gfgtdf 20161030 22:17:01< tad_carlucci> Ok. grabbing commit now ... 20161030 22:18:45< shadowm> gfgtdf: Hi, I wrote that code. Could you explain why your commit might work? According to http://www.boost.org/doc/libs/1_49_0/libs/filesystem/v3/doc/reference.html#is_directory2 , the error_code overload doesn't throw. 20161030 22:19:17< gfgtdf> shadowm: this is about is_empty, not is_directory 20161030 22:19:38< shadowm> "Returns: is_directory(s) ? directory_iterator(p) == directory_iterator() : file_size(p) == 0;" 20161030 22:20:07< shadowm> I believe this is pseudocode since it doesn't acknowledge the fact that is_empty() has an error_code overload. 20161030 22:20:09< tad_carlucci> Not the directory is not readable or executable. So you can't look in it or open files inside it unless you're root ... 20161030 22:20:20< shadowm> Yes tad_carlucci I know, I'm asking about the API. 20161030 22:20:33< gfgtdf> shadowm: well yes since is_directory doesn't throw this menas that the directory_iterator throqws. 20161030 22:21:02< shadowm> Seems like directory_iterator also has a constructor that takes an error_code. 20161030 22:21:02< gfgtdf> shadowm: the stacktract posted by tad above shows that is_empty does throw 20161030 22:21:22< shadowm> So wouldn't this be a bug in Boost.Filesystem too then? 20161030 22:21:57< tad_carlucci> You can't read the directory, so I'd expect is_directory to be OK but is_empty to throw. 20161030 22:22:10< gfgtdf> shadowm: i thought that aswell, but the documentation does not mark that is_empty overload as nothrow (unlike is directory) so i'm not sure 20161030 22:22:33< shadowm> http://www.boost.org/doc/libs/1_49_0/libs/filesystem/v3/doc/reference.html#Error-reporting 20161030 22:22:45< shadowm> "Functions having an argument of type system::error_code& report errors as follows, unless otherwise specified:" 20161030 22:23:27< shadowm> It doesn't say they'd throw an exception other than the usual exceptions from allocators. 20161030 22:23:41< tad_carlucci> Confirming commit 09d988b lets me use Load Map ... 20161030 22:24:06< shadowm> Also, why on earth is your /media not searchable? 20161030 22:24:44< shadowm> Actually, on second thought, I do not want to know. It's probably some weird DIY-related reason. 20161030 22:24:57< tad_carlucci> shadowm, *shrugs* I've never looked at it. 20161030 22:25:47< tad_carlucci> And the Window button does not provoke the non-fatal messages for AOI maps like it did on Windows. So I'm thinking it was just the / vs \ in the pathnames. 20161030 22:26:17< tad_carlucci> celticminstrel, I cannot reproduce you crash on Windows or Linux. 20161030 22:26:21< shadowm> The Window button that just brings up the Window menu...? 20161030 22:27:03< tad_carlucci> Yes. On Windows 10 I got console messages about bad pathnames. There were no spaces so the only issue I could see was some \ and some / all in the same pathname 20161030 22:27:19< shadowm> Bad path names, or bad escapes in Pango contexts? 20161030 22:27:28< tad_carlucci> pathnames. 20161030 22:27:42< shadowm> I don't think clicking on the Window button should call any path parsing code... 20161030 22:27:47< tad_carlucci> Let me see if I can copy/paste the full message. 20161030 22:28:24< gfgtdf> are there issues with spaces in pathnames? This would be quoite bad since the default programm instalation folder in windows has spaces in it. 20161030 22:28:34< shadowm> But it just occurred to me that throwing a Windows-native path into a GUI2 context with markup enabled might make Pango sad. 20161030 22:29:55< tad_carlucci> gfgtdf, I don't know about spaces. It was my first thoought so I looekd and there were none. 20161030 22:29:57< shadowm> E.g. in "C:\Users" there's an escape that Pango might or might not recognize (either result is bad). 20161030 22:30:46< gfgtdf> shadowm: i don't know whether the is_empty issue is a bug in boost, if you want to know you have to ask boost people or file a bugreport at boost. 20161030 22:31:03< shadowm> Yeah, good luck getting me to do that. :p 20161030 22:32:15< shadowm> I'd have to fetch the latest release from Git or SVN or whatever, build it myself, come up with a reproducible test case, probably write a test suite patch, etc. I'm too busy with other things atm. 20161030 22:33:01-!- tad_carlucci_ [~lundberg@173.217.65.103] has joined #wesnoth-dev 20161030 22:33:02-!- tadcarlucci [~lundberg@173.217.65.103] has joined #wesnoth-dev 20161030 22:33:35-!- tad__ [~lundberg@173.217.65.103] has joined #wesnoth-dev 20161030 22:33:45< tad__> Setting mode to 1312x798 20161030 22:33:45< tad__> WML exception: 20161030 22:33:45< tad__> User message: Failed to show a dialog, which doesn't fit on the screen. 20161030 22:33:45< tad__> Dev message: ..\..\src\gui\widgets\window.cpp:1034 in function 'gui2::twindow::layout' found the following problem: Failed to size window; wanted size 610,653 available size 800,600 screen size 800,600. 20161030 22:33:53< tad__> On Windows 10 20161030 22:34:08< tad__> And yes it would not size below 800x600 20161030 22:35:30< tad__> Setting mode to 800x600 20161030 22:35:30< tad__> Checking lua scripts... ok 20161030 22:35:30< tad__> 20161030 17:35:10 error filesystem: Failed to check existence of file C:\Users\Lundberg\Source\Repos\wesnoth/images/icons/action/[1] C:\Users\Lundberg\Source\Repos\wesnoth\data\campaigns\An_Orcish_Incursion\maps\01_Defend_the_Forest.map_25.png: The filename, directory name, or volume label syntax is incorrect 20161030 22:35:30< tad__> 20161030 17:35:10 error filesystem: Failed to check existence of file C:\Users\Lundberg\Source\Repos\wesnoth/images/icons/action/[2] C:\Users\Lundberg\Source\Repos\wesnoth\data\campaigns\An_Orcish_Incursion\maps\02_Assassins.map [*]_25.png: The filename, directory name, or volume label syntax is incorrect 20161030 22:35:45< tad__> Errors on Windows 10 from Window button on map editor^ 20161030 22:36:10< gfgtdf> tad__: this sounds to me liek the ' [*]' is teh bas part here 20161030 22:36:14< shadowm> Yeah that looks like a nonsense call. 20161030 22:36:26< shadowm> gfgtdf: I don't think that's the problem. 20161030 22:36:30< gfgtdf> tad__: the "Failed to show a dialog, which doesn't fit on the screen." is about whcih dialog ? 20161030 22:37:11< shadowm> Look at those timestamps. 20161030 22:37:12< tad_carlucci> One of the loadscreen screens when starting. 20161030 22:37:41< shadowm> The error message suggests that something is trying to check for a file "C:\Users\Lundberg\Source\Repos\wesnoth/images/icons/action/[1] C:\Users\Lundberg\Source\Repos\wesnoth\data\campaigns\An_Orcish_Incursion\maps\01_Defend_the_Forest.map_25.png". 20161030 22:38:02< shadowm> : cannot occur in path names in Windows other than in a drive specification*. 20161030 22:38:40< shadowm> So it looks to me like there's something really weird going on with whatever builds that menu. 20161030 22:38:40< gfgtdf> shadowm: i think * is an illegal chracter on windows aswell 20161030 22:38:47< tad_carlucci> Those messages are non-fatal, remember. The Window buttons works fine. 20161030 22:39:00< shadowm> It shouldn't be doing that regardless. 20161030 22:39:05 * tad_carlucci nods. 20161030 22:40:01-!- vultraz [~chatzilla@wesnoth/developer/vultraz] has quit [Ping timeout: 250 seconds] 20161030 22:40:34< gfgtdf> tad__: ypou have a stacktrace from where tht erro is printed ? 20161030 22:41:40< tad_carlucci> Which error? Not sure .. maybe .. if there's an throw involved .. need to run to the store give me a while. 20161030 22:42:20< gfgtdf> tad_carlucci: i dont think there is a thow involved 20161030 22:42:32< gfgtdf> tad_carlucci:maybe you coudl just set a brakpoint here https://github.com/wesnoth/wesnoth/blob/master/src/filesystem_boost.cpp#L235 20161030 22:44:23< shadowm> I suspect somethign is trying to image::get_image("images/icons/action/" + str + ".png") with str being the menu entry label (that for some reason isn't being basename'd like it is on Linux, probably because someone is making assumptions about path separators somewhere in the editor code). 20161030 22:44:31< shadowm> *something 20161030 22:44:50< shadowm> "icons/action/" rather. 20161030 22:45:09< shadowm> So, two things being done wrong there. 20161030 22:45:28< gfgtdf> shadowm: sounds likeley. 20161030 22:47:28< gfgtdf> shadowm: such a code is for example here: https://github.com/wesnoth/wesnoth/blob/master/src/hotkey/command_executor.cpp#L418 20161030 22:52:56-!- travis-ci [~travis-ci@ec2-54-226-86-179.compute-1.amazonaws.com] has joined #wesnoth-dev 20161030 22:52:57< travis-ci> wesnoth/wesnoth#11813 (master - 09d988b : gfgtdf): The build has errored. 20161030 22:52:58< travis-ci> Build details : https://travis-ci.org/wesnoth/wesnoth/builds/171850207 20161030 22:52:58-!- travis-ci [~travis-ci@ec2-54-226-86-179.compute-1.amazonaws.com] has left #wesnoth-dev [] 20161030 22:53:01< tad_carlucci> ok onion obtained, dinner saved and in process. let me try the breakpoint 20161030 22:53:29-!- tadcarlucci [~lundberg@173.217.65.103] has quit [Quit: Switching to Unix to get some real work done.] 20161030 22:58:48-!- vultraz [~chatzilla@wesnoth/developer/vultraz] has joined #wesnoth-dev 20161030 22:59:14-!- tad_carlucci_ [~lundberg@173.217.65.103] has quit [Quit: Switching to Unix to get some real work done.] 20161030 23:05:09-!- Appleman1234 [~Appleman1@KD036012032169.au-net.ne.jp] has quit [Ping timeout: 250 seconds] 20161030 23:10:43 * tad__ .oO ( I'm gonna have dinner ready and eaten before VS even starts this program ... ) 20161030 23:18:53< tad__> OK. I'm at the breakpoint. What would you like to know? 20161030 23:22:27< tad__> L"C:/Users/Lundberg/Source/Repos/wesnoth/images/icons/action/[1] C:\\Users\\Lundberg\\Source\\Repos\\wesnoth\\data\\campaigns\\An_Orcish_Incursion\\maps\\01_Defend_the_Forest.map_25.png" 20161030 23:23:05< celticminstrel> ...why is it treating a map as an image? 20161030 23:23:25< celticminstrel> Wait, why are their two paths tacked together there? 20161030 23:24:08< tad__> Because it went wrong earlier 20161030 23:24:13< celticminstrel> Oh, hmm, this seems like it would be for the editor maps menu, huh... 20161030 23:24:38< celticminstrel> I was refactoring stuff in that area but kinda gave up on it... 20161030 23:24:47-!- Appleman1234 [~Appleman1@KD106181164020.au-net.ne.jp] has joined #wesnoth-dev 20161030 23:24:53< vultraz> do return 20161030 23:27:22< tad__> command_executor get_menu_image line 429 20161030 23:28:12< tad__> base_image_name = "icons/action/[1] C:\\Users\\Lundberg\\Source\\Repos\\wesnoth\\data\\campaigns\\An_Orcish_Incursion\\maps\\01_Defend_the_Forest.map_25.png" 20161030 23:30:02-!- vultraz [~chatzilla@wesnoth/developer/vultraz] has quit [Ping timeout: 244 seconds] 20161030 23:32:25< gfgtdf> tad__: a stacktrace. 20161030 23:33:08< tad__> How to in vs 2015? 20161030 23:33:34< gfgtdf> tad__: there shodul be stacktrace tool when you debug an application 20161030 23:33:46< tad__> found a way 20161030 23:33:50< gfgtdf> tad__: dbug->windows->strcktrace or similar 20161030 23:33:56< gfgtdf> tad__: onyl know th german names 20161030 23:35:26< tad__> http://pastebin.com/TesDAQn2 20161030 23:36:01-!- ChipmunkV [~vova@static-89-94-113-91.axione.abo.bbox.fr] has quit [Quit: ChipmunkV] 20161030 23:38:28< tad__> "Call Stack" in en US, Alt-7, and it's on screen by default .. just needed to figure out how to select all and copy/paste 20161030 23:39:57-!- vultraz [~chatzilla@124.109.10.167] has joined #wesnoth-dev 20161030 23:39:57-!- vultraz [~chatzilla@124.109.10.167] has quit [Changing host] 20161030 23:39:57-!- vultraz [~chatzilla@wesnoth/developer/vultraz] has joined #wesnoth-dev 20161030 23:42:41-!- zookeeper [~lmsnie@wesnoth/developer/zookeeper] has quit [Ping timeout: 260 seconds] --- Log closed Mon Oct 31 00:00:21 2016