--- Log opened Mon Nov 21 00:00:15 2011 |
01:43 | | Kindamoody[zZz] is now known as Kindamoody |
01:56 | | gnolam [lenin@Nightstar-202a5047.priv.bahnhof.se] has quit [[NS] Quit: Z?] |
02:07 | | Kazriko [kazrikna@4CA975.462904.08E9A2.992A2D] has joined #code |
02:11 | | Attilla [Obsolete@Nightstar-f29f718d.cable.virginmedia.com] has quit [Ping timeout: 121 seconds] |
02:12 | | * McMartin rages at all-the-world-is-POSIX people |
02:12 | < McMartin> | "You will need cygwin to do this next step" |
02:12 | < sshine> | that's horrible. |
02:12 | < McMartin> | WE ALREADY HAD TO INSTALL PYTHON, THERE IS NO EXCUSE WHATSOEVER FOR BASH HERE. |
02:13 | | * McMartin rewrites it as Python, uses the os and os.path modules. |
02:23 | | Vornicus [vorn@ServerAdministrator.Nightstar.Net] has quit [Ping timeout: 121 seconds] |
02:26 | | Vornicus [vorn@ServerAdministrator.Nightstar.Net] has joined #code |
02:26 | | mode/#code [+qo Vornicus Vornicus] by ChanServ |
02:37 | | Eri [Eri@Nightstar-3e5deec3.gv.shawcable.net] has quit [Ping timeout: 121 seconds] |
02:44 | | Vornicus is now known as Finerty |
02:51 | | Eri [Eri@Nightstar-3e5deec3.gv.shawcable.net] has joined #code |
02:56 | | Syloqs-AFH [Syloq@NetworkAdministrator.Nightstar.Net] has quit [[NS] Quit: ] |
02:56 | < celticminstrel> | Heh. |
03:10 | | Syloqs_AFH [Syloq@NetworkAdministrator.Nightstar.Net] has joined #code |
03:12 | | Syloqs_AFH is now known as Syloqs-AFH |
03:54 | | Kindamoody is now known as Kindamoody|afk |
04:28 | | Derakon [Derakon@Nightstar-f68d7eb4.ca.comcast.net] has quit [Client exited] |
04:29 | | Kindamoody|afk is now known as Kindamoody |
04:34 | | Finerty is now known as Vornicus |
04:40 | | kwsn is now known as kw-sleep-n |
05:02 | | Derakon [Derakon@Nightstar-f68d7eb4.ca.comcast.net] has joined #code |
05:08 | | Kindamoody is now known as Kindamoody|out |
05:19 | | maoranma [maoranma@490720.C448F4.EA970A.EA912C] has joined #code |
05:20 | < sshine> | I wish PHP disallowed newline characters in strings. this guy is printing huge HTML blobs. |
05:20 | | Noah [maoranma@490720.C448F4.EA970A.EA912C] has quit [Ping timeout: 121 seconds] |
05:24 | < sshine> | also, for some reason, half of all strings that get printed are defined as constants in various files. |
05:26 | | * Ling hasn't dealt with a language that pukes on new-lines in strings yet |
05:26 | < Ling> | ... except JS |
05:40 | < McMartin> | Er |
05:40 | < McMartin> | Which languages have you used? |
05:41 | < McMartin> | The vast majority of languages either disallow this entirely or insist upon a special form for "strings with newlines in" or an escape code that means "newline inc" |
05:47 | < sshine> | Ling, Haskell, C, Standard ML. |
05:49 | < sshine> | Ling, if absolutely necessary I'd prefer the <<EOF ... EOF; syntax. |
05:49 | < McMartin> | C chokes on newlines in strings. |
05:49 | < McMartin> | It just also lets you concatenate strings at lex time. |
05:49 | < sshine> | yeah, that's pretty neat. |
05:50 | < sshine> | I'd prefer that too! |
05:59 | <~Vornicus> triplequoooootes |
06:00 | | ErikMesoy|sleep is now known as ErikMesoy |
06:31 | | Derakon is now known as Derakon[AFK] |
06:34 | | Stalker [Z@2C3C9C.B2A300.F245DE.859909] has quit [Ping timeout: 121 seconds] |
07:08 | | Reiver [orthianz@3CF3A5.E1CD01.C6689C.33956A] has quit [Ping timeout: 121 seconds] |
07:12 | | Reiver [orthianz@3CF3A5.E1CD01.C6689C.33956A] has joined #code |
07:46 | | Stalker [Z@Nightstar-3602cf5a.cust.comxnet.dk] has joined #code |
08:03 | | celticminstrel [celticminst@Nightstar-5d22ab1d.cable.rogers.com] has quit [[NS] Quit: And lo! The computer falls into a deep sleep, to awake again some other day!] |
08:03 | | Alek [omegaboot@Nightstar-10752b3e.il.comcast.net] has quit [Ping timeout: 121 seconds] |
09:20 | | Attilla [Obsolete@Nightstar-f29f718d.cable.virginmedia.com] has joined #code |
09:21 | | You're now known as TheWatcher |
09:55 | | RichardBarrell [richard@Nightstar-3b2c2db2.bethere.co.uk] has joined #code |
10:05 | < McMartin> | http://www.esolangs.org/wiki/Var%27aq#Leap_year |
10:05 | < McMartin> | A program written in Klingon, commented in Spanish, that prints English. |
10:06 | | * Tamber bashes something together in Forth, commented in bad German, that prints Perl (Commented in awful English) that generates LISP. |
10:07 | < Tamber> | (No, I'm not /actually/ going to do that; that's far too much Fun for one painful lifetime.) |
10:14 | < McMartin> | I am assuming that this program was written by a native Spanish speaker, and was using English for output because it is The Language Of Computers. |
10:14 | < Tamber> | Hmm. |
10:17 | | * TheWatcher eyes that link |
10:17 | < TheWatcher> | Some people have entirely too much time on their hands. |
10:19 | < McMartin> | var'aq was great |
10:19 | < McMartin> | Pity it was hosted on GeoCities. |
10:19 | | * TheWatcher shakesfist at geoshities |
11:18 | | Stalker [Z@Nightstar-3602cf5a.cust.comxnet.dk] has quit [Ping timeout: 121 seconds] |
12:00 | | * TheWatcher slaps idiots who can't even indent their code consistently |
12:02 | < TheWatcher> | I should not have to resort to ESC+<,C+space,ESC+>,C+M+\ to make code readable, damnit |
12:06 | < TheWatcher> | Also, have I ever mentioned that I hate PHP? Just saying... |
12:06 | < Tamber> | You might have hinted at feeling that way, yes. ;) |
12:17 | | * Tamber wtfs a little. |
12:23 | | cpux [cpux@Nightstar-c5874a39.dyn.optonline.net] has quit [[NS] Quit: Well, most things get better when I kick them!] |
12:30 | < McMartin> | Is this because they're tosspots or is it because they've been mixing spaces and tabs, in defiance of God and Country? |
12:31 | < TheWatcher> | The former. |
12:34 | < TheWatcher> | Some bits are indented by 1 space, others by 2, others by 4, with no apparent rhyme or reason. |
12:40 | | Stalker [Z@Nightstar-5aa18eaf.balk.dk] has joined #code |
12:46 | | Alek [omegaboot@Nightstar-10752b3e.il.comcast.net] has joined #code |
13:14 | | celticminstrel [celticminst@Nightstar-5d22ab1d.cable.rogers.com] has joined #code |
13:26 | | gnolam [lenin@Nightstar-202a5047.priv.bahnhof.se] has joined #code |
13:38 | < TheWatcher> | ... does anyone know when php changed its class constructor naming from "class Foo { function Foo(...) { } }" to "class Foo { function __construct(...) { } }" ? |
13:44 | < Tamber> | Shortly after someone went "Oh, man, they'll get a kick out of this!" |
13:45 | < TheWatcher> | Yeah, well, I think 90% of the langauge came about that way. I just want to know whether using __construct will work on 5.1.3, and it seems the only way I can find that out is to actually /try it/, because they are dicks and don't actually provide documentation for old versions. |
13:47 | < Tamber> | Of course not, that would be useful. |
14:26 | | kw-sleep-n is now known as kwsn |
14:49 | < Ling> | TheWatcher: PHP 5 when all the massive OOP fixes came in |
14:49 | < Ling> | Also, it's documented in the Classes and Objects section |
14:51 | < Ling> | "For backwards compatibility, if PHP 5 cannot find a __construct() function for a given class, it will search for the old-style constructor function, by the name of the class. Effectively, it means that the only case that would have compatibility issues is if the class had a method named __construct() which was used for different semantics." |
14:51 | < Ling> | http://www.php.net/manual/en/language.oop5.decon.php |
14:52 | < Ling> | (They used to have a section for PHP4-style classes, looks like that's gone |
14:52 | < TheWatcher> | Oh, I've seen that. But it doesn't actually say which version of php5. And the php devs just fucking love to throw in ridiculous changes between minor versions, so it's not like you can even count on "php 5" meaning "all of php5" or "just some version, we can't be arsed to tell you which" |
14:54 | < Ling> | Aye, that's a change that came with PHP 5.0.0 though |
14:54 | < TheWatcher> | Fair enough. Thanks. |
14:54 | < Ling> | Sadly not on the changelog page for OOP :/ |
14:55 | < TheWatcher> | Mmhmm |
14:55 | < TheWatcher> | not like it's important enough to document, after all. |
14:56 | < Ling> | Really though, why are you using such an old version? |
14:56 | < TheWatcher> | Oh, I'm not - all my machines run 5.3.8 |
14:57 | < TheWatcher> | unfortunately, the IS people in work believe that CentOS is the moseawesomewonderfulgreat distro of all time |
14:57 | < Tamber> | "If it still compiles, it's not stable enough." |
14:58 | < TheWatcher> | The 'normal' install of php on CentOS is 5.1.3. I believe you /can/ make CentOS install 5.2, however the machine this needs to run on happens to be one of the ones I don't have root access on |
14:58 | < Ling> | D: |
14:58 | < TheWatcher> | (and I'd probably get lynched if I swapped in a new version anyway) |
15:00 | < Ling> | Anyways, here's some rage fuel: json_encode and json_decode were introduced sometime in PHP 5 before 5.3. json_decode can fail and will return false when it does. To get the error you need PHP 5.3 because that actually introduced the function needed to get an error code.. |
15:01 | | PuerScyphu [PuerScyphu@Nightstar-ebc709f9.inturbo.lt] has joined #code |
15:02 | < Tamber> | ... |
15:02 | < Ling> | Also, __autoload couldn't catch exceptions until 5.3 |
15:02 | < PuerScyphu> | http://baron.proudandloud.com Create your own unique T-SHIRT.In our website you can upload your image and create your own design and order the product you made |
15:03 | | PuerScyphu [PuerScyphu@Nightstar-ebc709f9.inturbo.lt] has left #code [] |
15:03 | < Tamber> | ...whut. |
15:03 | < TheWatcher> | Sounds like mysqli::connect_error, which was broken until 5.2.9, unless you called it as mysql_connect_error() instead of $database -> connect_error. |
15:03 | < TheWatcher> | *mysqli_connect_error |
15:04 | < TheWatcher> | But anyway. Some commenting, and then I can hopefully return to more sane languages for a while |
15:05 | < Eri> | Stupid bot |
15:05 | < Eri> | It missed #math, which is definitely in the channel list |
15:06 | < Eri> | Wonder if it's in the oubliette |
15:08 | | * celticminstrel wonders if it could possibly be dangerous to accept regex input to be inserted into a larger regex expression. |
15:09 | < Tamber> | If you have to ask that, the answer is always "Yes" ;) |
15:10 | < celticminstrel> | <_< |
15:10 | | * Ling doesn't see how regex could be an attack vector |
15:10 | < Tamber> | Precisely! *cranks up the paranoia a notch or several* |
15:11 | < Tamber> | No, I don't know, either; but still... |
15:11 | < TheWatcher> | cm: which language, and rexexp flavour, might make a difference too. |
15:12 | < celticminstrel> | PHP, preg. |
15:13 | < Tamber> | Well, you could always run it through a regex to check it's not dangerous, right? *runs away before the brick lands* |
15:13 | < TheWatcher> | (if nothing else, an attacker can craft an expression that will make the regexp get stuck in a loop or something) |
15:14 | < celticminstrel> | Hm, stuck in a loop wouldn't be good. |
15:16 | | Eri [Eri@Nightstar-3e5deec3.gv.shawcable.net] has quit [Ping timeout: 121 seconds] |
15:19 | < celticminstrel> | I kinda like the x[] = y syntax for append... |
15:22 | < RichardBarrell> | Ling: I thought that maybe Perl's regexes might have features where you can throw Perl expressions in inline. |
15:23 | < Ling> | Yeah, that'd be dangerous, but PCRE doesn't have that feature AFAIK |
15:23 | < RichardBarrell> | If you have a backtracking regular expression engine then someone can hand you a pattern like (a?a?a?a?a?a?a?a?a?a?a?a?a?a?a?) and it'll blow up, or I think that ((.*)\1\1\1\1\1\1\1\1\1) can blow up. |
15:24 | < Ling> | RE:x[] = y, yeah, they actually deprecated array_push() at one point because of it being redundant. |
15:24 | < RichardBarrell> | By "blow up" I mean "hit the exponential worst-case" |
15:25 | < RichardBarrell> | If you want to let strangers hand you regexps then you have to use a real regular expression engine, i.e. one that doesn't implement backreferences in the pattern and lazily builds a DFA as it traverses the input text. |
15:25 | < RichardBarrell> | That or you set a timeout for evaluation. |
15:30 | | Eri [Eri@Nightstar-3e5deec3.gv.shawcable.net] has joined #code |
15:36 | | maoranma [maoranma@490720.C448F4.EA970A.EA912C] has quit [Ping timeout: 121 seconds] |
15:38 | | maoranma [maoranma@490720.C448F4.EA970A.EA912C] has joined #code |
15:38 | | Eri [Eri@Nightstar-3e5deec3.gv.shawcable.net] has quit [Ping timeout: 121 seconds] |
15:51 | | Eri [Eri@Nightstar-3e5deec3.gv.shawcable.net] has joined #code |
16:03 | < celticminstrel> | preg_match doesn't seem to allow the latter. |
17:09 | < celticminstrel> | Hm, encoding issues... where would it come from, the file() call? |
17:09 | < celticminstrel> | Or htmlspecialchars? |
17:09 | | kwsn is now known as kw\o-o-i |
17:10 | < celticminstrel> | If it's file(), how can I tell PHP that it should be read as Unicode? |
17:12 | | * Tamber sacrifices a chicken for celticminstrel. |
17:13 | < celticminstrel> | Heh. |
17:17 | | kw\o-o-i is now known as kw |
17:19 | | mao42ranma [maoranma@490720.C448F4.EA970A.EA912C] has joined #code |
17:21 | | maoranma [maoranma@490720.C448F4.EA970A.EA912C] has quit [Ping timeout: 121 seconds] |
17:23 | | mao42ranma [maoranma@490720.C448F4.EA970A.EA912C] has quit [Ping timeout: 121 seconds] |
17:26 | | Kindamoody|out is now known as Kindamoody |
17:26 | < RichardBarrell> | celticminstrel: a timeout? I wouldn't expect preg_match to have that, and I wouldn't trust one in there anyway. |
17:28 | < RichardBarrell> | Doing timeout'd operations really reliably requires you to spawn a child process, then wait for that process (which you *can* give a timeout for) and murder the child process if it's still running. |
17:28 | < celticminstrel> | Ah. |
17:29 | < Attilla> | that sounds dirty |
17:29 | < RichardBarrell> | You run the possibly-an-infinite-loop in the child process. Also, you have the child process use setrlimit() (and I'm sure Windows has an equivalent) to restrict itself to a maximum possible CPU time expenditure too, just to be safe. |
17:30 | < RichardBarrell> | It's fine. fork() to your heart's content, just like Korn and your mother always intended you to. |
17:33 | | * TheWatcher pushes out Megaphone v0.6 (Aldgate East), collapse vaguely |
17:53 | | celticminstrel is now known as celmin|away |
18:36 | | Kindamoody is now known as Kindamoody[zZz] |
18:42 | < ErikMesoy> | My informatics lecturer is either very bad at english or else makes a lot of typoes in the lecture notes he distributes to the class. |
18:43 | < ErikMesoy> | The highlight of the day was how two nodes are "adjacenct" if connected by an edge of a graph. |
18:44 | < TheWatcher> | That's... pretty impressive for a typo |
19:08 | | ErikMesoy [Erik_Mesoy@Nightstar-f7eedefa.80-203-17.nextgentel.com] has quit [Ping timeout: 121 seconds] |
19:16 | | Erik|Finagled [Erik_Mesoy@Nightstar-f7eedefa.80-203-17.nextgentel.com] has joined #code |
19:17 | < Erik|Finagled> | Okay, that crossed the line from Murphy to Finagle. :p |
19:17 | | Erik|Finagled is now known as ErikMesoy |
19:18 | < ErikMesoy> | Normally I do my informatics homework in the evening of the day it's due. |
19:18 | < ErikMesoy> | This instance is due tomorrow. I was doing it early while complaining about the poor lecturer. So I finish the informatics homework. Open university page to hand it in. Go to student login section. "Could not locate server." |
19:18 | < ErikMesoy> | Internet has gone, rebooting modem and computer didn't help, eventually it came back several minutes later. |
19:19 | < ErikMesoy> | Lesson learned: hand in homework the evening it's due. :P Trying to get it done early just results in the internet going "How about no". :P |
19:23 | < gnolam> | :) |
19:56 | | celmin|away is now known as celticminstrel |
20:28 | | RichardBarrell [richard@Nightstar-3b2c2db2.bethere.co.uk] has quit [Client closed the connection] |
21:51 | | Stalker [Z@Nightstar-5aa18eaf.balk.dk] has quit [Ping timeout: 121 seconds] |
22:13 | | Vornicus [vorn@ServerAdministrator.Nightstar.Net] has quit [[NS] Quit: ] |
22:25 | | ErikMesoy is now known as ErikMesoy|sleep |
22:49 | | kw is now known as kw\afk |
23:47 | | cpux [cpux@Nightstar-c5874a39.dyn.optonline.net] has joined #code |
23:50 | | Noah [maoranma@490720.C448F4.EA970A.EA912C] has joined #code |
23:53 | | You're now known as TheWatcher[T-2] |
23:57 | | You're now known as TheWatcher[zZzZ] |
--- Log closed Tue Nov 22 00:00:30 2011 |