Michael Banck wrote: >On Mon, Aug 16, 2004 at 03:15:52PM +0100, [EMAIL PROTECTED] wrote: >> jack doesn't cope properly with CDs whose track titles have non >> ISO-8859-1 characters in them. >> I made a quick hack change to my copy of jack so it used protocol >> level 6, and it seems to work OK
>sorry I forgot to reply. I talked to upstream about this, and he said >he'd address this once he got time (which is pretty rare) > >Could you send me the patch for this, please? I append it here, but it is of course not suitable to apply as-is (it's against the older version of jack, for a start!) Apart from some debugging print statements, it does the bare minimum: requesting protocol 6 in queries, and handling the new 210 response. There's a lot that needs to be done here to make this proper production quality. -- PMM ===begin=== --- /usr/bin/jack.orig Sun Nov 21 17:19:54 2004 +++ /usr/bin/jack.pmm Sun Nov 21 17:19:39 2004 @@ -1393,12 +1393,13 @@ qs = qs + `i[START] + MSF_OFFSET` + " " qs = qs + `(MSF_OFFSET + tracks[-1][START] + tracks[-1][LEN]) / CDDA_BLOCKS_PER_SECOND` hello = "hello=" + username + " " + hostname + " " + freedb_servers[freedb_server]['id'] - qs = quote_plus(qs + "&" + hello + "&proto=3", "=&") + qs = quote_plus(qs + "&" + hello + "&proto=6", "=&") url = "http://" + freedb_servers[freedb_server]['host'] + "/~cddb/cddb.cgi?" + qs + print "opening url " + url # PMM f = urlopen(url) buf = f.readline() if buf and buf[0:1] == "2": - if buf[0:3] == "211": # Found inexact matches, list follows + if buf[0:3] == "211" or buf[0:3] == "210" : # Found inexact matches or multiple exact matches, list follows print "Found inexact matches choose one:" num = 1 matches = [] @@ -1443,7 +1444,8 @@ exit() cmd = "cmd=cddb read " + freedb_cat + " " + cd_id - url = "http://" + freedb_servers[freedb_server]['host'] + "/~cddb/cddb.cgi?" + quote_plus(cmd + "&" + hello + "&proto=3", "=&") + url = "http://" + freedb_servers[freedb_server]['host'] + "/~cddb/cddb.cgi?" + quote_plus(cmd + "&" + hello + "&proto=6", "=&") + print "2 opening url " + url # PMM f = urlopen(url) buf = f.readline() if buf and buf[0:3] == "210": # entry follows @@ -1452,6 +1454,7 @@ of = open(file, "w") buf = f.readline() while buf: + print "raw data " + buf buf = rstrip(buf) if buf != ".": of.write(buf + "\n") ===endit=== -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]