From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Juanma Barranquero Newsgroups: gmane.emacs.devel Subject: Re: [PATCH] GnuTLS support on Woe32 Date: Wed, 4 May 2011 05:25:07 +0200 Message-ID: References: <87ipvwl1nx.wl%claudio.bley@gmail.com> <87bp11imgb.wl%claudio.bley@gmail.com> <8739mc5nes.fsf@lifelogs.com> <87ipuubao6.fsf@lifelogs.com> <87fwpjfkkz.fsf@lifelogs.com> <87bp072fb1.fsf@lifelogs.com> <874o5vimm5.fsf@lifelogs.com> <87zknjmcyk.fsf@lifelogs.com> <87sjta2zvp.fsf@lifelogs.com> <87liyzglkh.fsf@lifelogs.com> <4DB77682.1070605@gmail.com> <8762q04ba1.fsf@lifelogs.com> <87hb9dufao.fsf@lifelogs.com> <87d3jzc0ct.fsf@lifelogs.com> <878vundy98.fsf@lifelogs.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary=00151748dcc006978804a26ad018 X-Trace: dough.gmane.org 1304479560 23041 80.91.229.12 (4 May 2011 03:26:00 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Wed, 4 May 2011 03:26:00 +0000 (UTC) Cc: emacs-devel@gnu.org To: Ted Zlatanov Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Wed May 04 05:25:55 2011 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([140.186.70.17]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1QHSin-0004dQ-T6 for ged-emacs-devel@m.gmane.org; Wed, 04 May 2011 05:25:54 +0200 Original-Received: from localhost ([::1]:58225 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QHSin-0007Yl-2y for ged-emacs-devel@m.gmane.org; Tue, 03 May 2011 23:25:53 -0400 Original-Received: from eggs.gnu.org ([140.186.70.92]:59204) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QHSij-0007YV-MM for emacs-devel@gnu.org; Tue, 03 May 2011 23:25:50 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QHSii-0005us-EB for emacs-devel@gnu.org; Tue, 03 May 2011 23:25:49 -0400 Original-Received: from mail-gx0-f169.google.com ([209.85.161.169]:44880) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QHSih-0005uo-T1 for emacs-devel@gnu.org; Tue, 03 May 2011 23:25:48 -0400 Original-Received: by gxk23 with SMTP id 23so333726gxk.0 for ; Tue, 03 May 2011 20:25:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc:content-type; bh=fcRPnQ9kE5fOso1P5FpDCkouE2wJvB/xXckXKri8h6k=; b=ZHQ4NUecNufbGXbmqG3prozFQY42jaqwsagKxSbQxNqM1JW++QUq/XHZolgoW0S01U ENklsa1pyhdPxTjtiGpoRaHC12oa6HwTRNg1RSDAYz7AvETARDHuf2g/Zd87YPM6zIuZ FmhBDnnxjkvQREFusNv9SS5MHpvkE+yQrVbBY= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-type; b=njJwjmx0zZYfQ7LaE7L91oyRfmdKv+M+eCq6RocHNwXRqjWicNFMic8JwPArMvUNcX cj03qSW5dcEYUoHjPe7hvR1B0eXkN698fQdIkEtvI3Rrpfq2R5GpVmwhL9l3xDmTPQTQ dmd/FolDDKiPKTkbSz1wrDw8mEqkjGVC55hkQ= Original-Received: by 10.150.73.20 with SMTP id v20mr597059yba.368.1304479547168; Tue, 03 May 2011 20:25:47 -0700 (PDT) Original-Received: by 10.147.182.5 with HTTP; Tue, 3 May 2011 20:25:07 -0700 (PDT) In-Reply-To: <878vundy98.fsf@lifelogs.com> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) X-Received-From: 209.85.161.169 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:139094 Archived-At: --00151748dcc006978804a26ad018 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable 2011/5/4 Ted Zlatanov : > Could you push it into the :dll property of that symbol (always a list)? > Then just loop on all the names when logging later. What I've done is to add a property :loaded-from to the library-id (the symbol identifying the library). So in case the loading fails, I just log that it failed, but not the filenames that were tried, because they are exactly (cdr (assq 'gnutls dynamic-library-alist)). If the loading is successfull, I log the filename too. > You could just say GNUTLS_LOG2 (1, 1, "loading the GnuTLS DLL: ", > filename) so it's unconditional (not the end of the world) I've opted for the easiest option, so GNUTLS_LOG2 (1, 1, ...). Feel free to change it once installed. Attached is the third version of the patch. =C2=A0 =C2=A0 Juanma --00151748dcc006978804a26ad018 Content-Type: application/octet-stream; name="gnutls3.patch" Content-Disposition: attachment; filename="gnutls3.patch" Content-Transfer-Encoding: base64 X-Attachment-Id: f_gn9pdxx70 PT09IG1vZGlmaWVkIGZpbGUgJ2xpc3AvdGVybS93MzItd2luLmVsJw0KLS0tIGxpc3AvdGVybS93 MzItd2luLmVsCTIwMTEtMDItMDMgMDc6MzE6NDIgKzAwMDANCisrKyBsaXNwL3Rlcm0vdzMyLXdp bi5lbAkyMDExLTA1LTAyIDAxOjEyOjQyICswMDAwDQpAQCAtMjA4LDcgKzIwOCw4IEBADQogICAg ICAgICAnKHN2ZyAibGlicnN2Zy0yLTIuZGxsIikNCiAgICAgICAgICcoZ2RrLXBpeGJ1ZiAibGli Z2RrX3BpeGJ1Zi0yLjAtMC5kb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uX3QsIGdudXRsc19hbGVydF9nZXQsDQorICAgICAgICAgICAg ICAgKGdudXRsc19zZXNzaW9uX3QpKTsNCitERUZfR05VVExTX0ZOIChjb25zdCBjaGFyICosIGdu dXRsc19hbGVydF9nZXRfbmFtZSwNCisgICAgICAgICAgICAgICAoZ251dGxzX2FsZXJ0X2Rlc2Ny aXB0aW9uX3QpKTsNCitERUZfR05VVExTX0ZOIChpbnQsIGdudXRsc19hbGVydF9zZW5kX2FwcHJv cHJpYXRlLCAoZ251dGxzX3Nlc3Npb25fdCwgaW50KSk7DQorREVGX0dOVVRMU19GTiAoaW50LCBn bnV0bHNfYW5vbl9hbGxvY2F0ZV9jbGllbnRfY3JlZGVudGlhbHMsDQorICAgICAgICAgICAgICAg KGdudXRsc19hbm9uX2NsaWVudF9jcmVkZW50aWFsc190ICopKTsNCitERUZfR05VVExTX0ZOICh2 b2lkLCBnbnV0bHNfYW5vbl9mcmVlX2NsaWVudF9jcmVkZW50aWFscywNCisgICAgICAgICAgICAg ICAoZ251dGxzX2Fub25fY2xpZW50X2NyZWRlbnRpYWxzX3QpKTsNCitERUZfR05VVExTX0ZOIChp bnQsIGdudXRsc19ieWUsIChnbnV0bHNfc2Vzc2lvbl90LCBnbnV0bHNfY2xvc2VfcmVxdWVzdF90 KSk7DQorREVGX0dOVVRMU19GTiAoaW50LCBnbnV0bHNfY2VydGlmaWNhdGVfYWxsb2NhdGVfY3Jl ZGVudGlhbHMsDQorICAgICAgICAgICAgICAgKGdudXRsc19jZXJ0aWZpY2F0ZV9jcmVkZW50aWFs c190ICopKTsNCitERUZfR05VVExTX0ZOICh2b2lkLCBnbnV0bHNfY2VydGlmaWNhdGVfZnJlZV9j cmVkZW50aWFscywNCisgICAgICAgICAgICAgICAoZ251dGxzX2NlcnRpZmljYXRlX2NyZWRlbnRp YWxzX3QpKTsNCitERUZfR05VVExTX0ZOIChjb25zdCBnbnV0bHNfZGF0dW1fdCAqLCBnbnV0bHNf Y2VydGlmaWNhdGVfZ2V0X3BlZXJzLA0KKyAgICAgICAgICAgICAgIChnbnV0bHNfc2Vzc2lvbl90 LCB1bnNpZ25lZCBpbnQgKikpOw0KK0RFRl9HTlVUTFNfRk4gKHZvaWQsIGdudXRsc19jZXJ0aWZp Y2F0ZV9zZXRfdmVyaWZ5X2ZsYWdzLA0KKyAgICAgICAgICAgICAgIChnbnV0bHNfY2VydGlmaWNh dGVfY3JlZGVudGlhbHNfdCwgdW5zaWduZWQgaW50KSk7DQorREVGX0dOVVRMU19GTiAoaW50LCBn bnV0bHNfY2VydGlmaWNhdGVfc2V0X3g1MDlfY3JsX2ZpbGUsDQorICAgICAgICAgICAgICAgKGdu dXRsc19jZXJ0aWZpY2F0ZV9jcmVkZW50aWFsc190LCBjb25zdCBjaGFyICosDQorICAgICAgICAg ICAgICAgIGdudXRsc194NTA5X2NydF9mbXRfdCkpOw0KK0RFRl9HTlVUTFNfRk4gKGludCwgZ251 dGxzX2NlcnRpZmljYXRlX3NldF94NTA5X2tleV9maWxlLA0KKyAgICAgICAgICAgICAgIChnbnV0 bHNfY2VydGlmaWNhdGVfY3JlZGVudGlhbHNfdCwgY29uc3QgY2hhciAqLCBjb25zdCBjaGFyICos DQorICAgICAgICAgICAgICAgIGdudXRsc194NTA5X2NydF9mbXRfdCkpOw0KK0RFRl9HTlVUTFNf Rk4gKGludCwgZ251dGxzX2NlcnRpZmljYXRlX3NldF94NTA5X3RydXN0X2ZpbGUsDQorICAgICAg ICAgICAgICAgKGdudXRsc19jZXJ0aWZpY2F0ZV9jcmVkZW50aWFsc190LCBjb25zdCBjaGFyICos DQorICAgICAgICAgICAgICAgIGdudXRsc194NTA5X2NydF9mbXRfdCkpOw0KK0RFRl9HTlVUTFNf Rk4gKGdudXRsc19jZXJ0aWZpY2F0ZV90eXBlX3QsIGdudXRsc19jZXJ0aWZpY2F0ZV90eXBlX2dl dCwNCisgICAgICAgICAgICAgICAoZ251dGxzX3Nlc3Npb25fdCkpOw0KK0RFRl9HTlVUTFNfRk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NfeDUwOV9jcnRfY2hlY2tfaG9zdG5hbWUsDQorICAgICAgICAgICAgICAgKGdudXRsc194 NTA5X2NydF90LCBjb25zdCBjaGFyICopKTsNCitERUZfR05VVExTX0ZOICh2b2lkLCBnbnV0bHNf eDUwOV9jcnRfZGVpbml0LCAoZ251dGxzX3g1MDlfY3J0X3QpKTsNCitERUZfR05VVExTX0ZOIChp bnQsIGdudXRsc194NTA5X2NydF9pbXBvcnQsDQorICAgICAgICAgICAgICAgKGdudXRsc194NTA5 X2NydF90LCBjb25zdCBnbnV0bHNfZGF0dW1fdCAqLA0KKyAgICAgICAgICAgICAgICBnbnV0bHNf eDUwOV9jcnRfZm10X3QpKTsNCitERUZfR05VVExTX0ZOIChpbnQsIGdudXRsc194NTA5X2NydF9p bml0LCAoZ251dGxzX3g1MDlfY3J0X3QgKikpOw0KKw0KK3N0YXRpYyBpbnQNCitpbml0X2dudXRs c19mdW5jdGlvbnMgKExpc3BfT2JqZWN0IGxpYnJhcmllcykNCit7DQorICBITU9EVUxFIGxpYnJh cnk7DQorDQorICBpZiAoIShsaWJyYXJ5ID0gdzMyX2RlbGF5ZWRfbG9hZCAobGlicmFyaWVzLCBR Z251dGxzX2RsbCkpKQ0KKyAgICB7DQorICAgICAgR05VVExTX0xPRyAoMSwgMSwgIkdudVRMUyBs aWJyYXJ5IG5vdCBmb3VuZCIpOw0KKyAgICAgIHJldHVybiAwOw0KKyAgICB9DQorDQorICBMT0FE X0dOVVRMU19GTiAobGlicmFyeSwgZ251dGxzX2FsZXJ0X2dldCk7DQorICBMT0FEX0dOVVRMU19G TiAobGlicmFyeSwgZ251dGxzX2FsZXJ0X2dldF9uYW1lKTsNCisgIExPQURfR05VVExTX0ZOIChs aWJyYXJ5LCBnbnV0bHNfYWxlcnRfc2VuZF9hcHByb3ByaWF0ZSk7DQorICBMT0FEX0dOVVRMU19G TiAobGlicmFyeSwgZ251dGxzX2Fub25fYWxsb2NhdGVfY2xpZW50X2NyZWRlbnRpYWxzKTs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LA0KICAgICAgICAgICAgICAgICAgZmlsZV9mb3JtYXQpOw0K QEAgLTYyNyw3ICs4NDEsNyBAQA0KICAgICAgICAgICAgIHsNCiAgICAgICAgICAgICAgIEdOVVRM U19MT0cyICgxLCBtYXhfbG9nX2xldmVsLCAic2V0dGluZyB0aGUgQ1JMIGZpbGU6ICIsDQogICAg ICAgICAgICAgICAgICAgICAgICAgICAgU1NEQVRBIChjcmxmaWxlKSk7DQotICAgICAgICAgICAg ICByZXQgPSBnbnV0bHNfY2VydGlmaWNhdGVfc2V0X3g1MDlfY3JsX2ZpbGUNCisgICAgICAgICAg ICAgIHJldCA9IGZuX2dudXRsc19jZXJ0aWZpY2F0ZV9zZXRfeDUwOV9jcmxfZmlsZQ0KICAgICAg ICAgICAgICAgICAoeDUwOV9jcmVkLA0KICAgICAgICAgICAgICAgICAgU1NEQVRBIChjcmxmaWxl KSwNCiAgICAgICAgICAgICAgICAgIGZpbGVfZm9ybWF0KTsNCkBAIC02NTIsNyArODY2LDcgQEAN CiAgICAgICAgICAgICAgICAgICAgICAgICAgICBTU0RBVEEgKGtleWZpbGUpKTsNCiAgICAgICAg ICAgICAgIEdOVVRMU19MT0cyICgxLCBtYXhfbG9nX2xldmVsLCAic2V0dGluZyB0aGUgY2xpZW50 IGNlcnQgZmlsZTogIiwNCiAgICAgICAgICAgICAgICAgICAgICAgICAgICBTU0RBVEEgKGNlcnRm aWxlKSk7DQotICAgICAgICAgICAgICByZXQgPSBnbnV0bHNfY2VydGlmaWNhdGVfc2V0X3g1MDlf a2V5X2ZpbGUNCisgICAgICAgICAgICAgIHJldCA9IGZuX2dudXRsc19jZXJ0aWZpY2F0ZV9zZXRf eDUwOV9rZXlfZmlsZQ0KICAgICAgICAgICAgICAgICAoeDUwOV9jcmVkLA0KICAgICAgICAgICAg ICAgICAgU1NEQVRBIChjZXJ0ZmlsZSksDQogICAgICAgICAgICAgICAgICBTU0RBVEEgKGtleWZp bGUpLA0KQEAgLTY4NSw3ICs4OTksNy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QogICAgIHsNCi0gICAgICByZXQgPSBnbnV0bHNfeDUwOV9jcnRfaW5pdCAoJmdudXRs c192ZXJpZnlfY2VydCk7DQorICAgICAgcmV0ID0gZm5fZ251dGxzX3g1MDlfY3J0X2luaXQgKCZn bnV0bHNfdmVyaWZ5X2NlcnQpOw0KIA0KICAgICAgIGlmIChyZXQgPCBHTlVUTFNfRV9TVUNDRVNT KQ0KICAgICAgICAgcmV0dXJuIGdudXRsc19tYWtlX2Vycm9yIChyZXQpOw0KIA0KICAgICAgIGdu dXRsc192ZXJpZnlfY2VydF9saXN0ID0NCi0gICAgICAgIGdudXRsc19jZXJ0aWZpY2F0ZV9nZXRf cGVlcnMgKHN0YXRlLCAmZ251dGxzX3ZlcmlmeV9jZXJ0X2xpc3Rfc2l6ZSk7DQorICAgICAgICBm bl9nbnV0bHNfY2VydGlmaWNhdGVfZ2V0X3BlZXJzIChzdGF0ZSwgJmdudXRsc192ZXJpZnlfY2Vy dF9saXN0X3NpemUpOw0KIA0KICAgICAgIGlmIChOVUxMID09IGdudXRsc192ZXJpZnlfY2VydF9s aXN0KQ0KICAgICAgICAgew0KQEAgLTgxOCwxNyArMTAzMiwxNyBAQA0KICAgICAgICAgfQ0KIA0K ICAgICAgIC8qIFdlIG9ubHkgY2hlY2sgdGhlIGZpcnN0IGNlcnRpZmljYXRlIGluIHRoZSBnaXZl biBjaGFpbi4gICovDQotICAgICAgcmV0ID0gZ251dGxzX3g1MDlfY3J0X2ltcG9ydCAoZ251dGxz X3ZlcmlmeV9jZXJ0LA0KKyAgICAgIHJldCA9IGZuX2dudXRsc194NTA5X2NydF9pbXBvcnQgKGdu dXRsc192ZXJpZnlfY2VydCwNCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAm Z251dGxzX3ZlcmlmeV9jZXJ0X2xpc3RbMF0sDQogICAgICAgICAgICAgICAgICAgICAgICAgICAg ICAgICAgICAgR05VVExTX1g1MDlfRk1UX0RFUik7DQogDQogICAgICAgaWYgKHJldCA8IEdOVVRM U19FX1NVQ0NFU1MpDQogICAgICAgICB7DQotICAgICAgICAgIGdudXRsc194NTA5X2NydF9kZWlu aXQgKGdudXRsc192ZXJpZnlfY2VydCk7DQorICAgICAgICAgIGZuX2dudXRsc194NTA5X2NydF9k ZWluaXQgKGdudXRsc192ZXJpZnlfY2VydCk7DQogICAgICAgICAgIHJldHVybiBnbnV0bHNfbWFr ZV9lcnJvciAocmV0KTsNCiAgICAgICAgIH0NCiANCi0gICAgICBpZiAoIWdudXRsc194NTA5X2Ny dF9jaGVja19ob3N0bmFtZSAoZ251dGxzX3ZlcmlmeV9jZXJ0LCBjX2hvc3RuYW1lKSkNCisgICAg ICBpZiAoIWZuX2dudXRsc194NTA5X2NydF9jaGVja19ob3N0bmFtZSAoZ251dGxzX3ZlcmlmeV9j ZXJ0LCBjX2hvc3RuYW1lKSkNCiAgICAgICAgIHsNCiAgICAgICAgICAgaWYgKE5JTFAgKHZlcmlm eV9ob3N0bmFtZV9lcnJvcikpDQogICAgICAgICAgICAgew0KQEAgLTgzNywxMyArMTA1MSwxMyBA QA0KICAgICAgICAgICAgIH0NCiAgICAgICAgICAgZWxzZQ0KICAgICAgICAgICAgIHsNCi0gICAg ICAgICAgICAgIGdudXRsc194NTA5X2NydF9kZWluaXQgKGdudXRsc192ZXJpZnlfY2VydCk7DQor ICAgICAgICAgICAgICBmbl9nbnV0bHNfeDUwOV9jcnRfZGVpbml0IChnbnV0bHNfdmVyaWZ5X2Nl cnQpOw0KICAgICAgICAgICAgICAgZXJyb3IgKCJUaGUgeDUwOSBjZXJ0aWZpY2F0ZSBkb2VzIG5v dCBtYXRjaCBcIiVzXCIiLA0KICAgICAgICAgICAgICAgICAgICAgIGNfaG9zdG5hbWUpOw0KICAg ICAgICAgICAgIH0NCiAgICAgICAgIH0NCiANCi0gICAgICBnbnV0bHNfeDUwOV9jcnRfZGVpbml0 IChnbnV0bHNfdmVyaWZ5X2NlcnQpOw0KKyAgICAgIGZuX2dudXRsc194NTA5X2NydF9kZWluaXQg KGdudXRsc192ZXJpZnlfY2VydCk7DQogICAgIH0NCiANCiAgIHJldHVybiBnbnV0bHNfbWFrZV9l cnJvciAocmV0KTsNCkBAIC04NzIsNyArMTA4Niw3IEBADQogDQogICBzdGF0ZSA9IFhQUk9DRVNT IChwcm9jKS0+Z251dGxzX3N0YXRlOw0KIA0KLSAgcmV0ID0gZ251dGxzX2J5ZSAoc3RhdGUsDQor ICByZXQgPSBmbl9nbnV0bHNfYnllIChzdGF0ZSwNCiAgICAgICAgICAgICAgICAgICAgIE5JTFAg KGNvbnQpID8gR05VVExTX1NIVVRfUkRXUiA6IEdOVVRMU19TSFVUX1dSKTsNCiANCiAgIHJldHVy biBnbnV0bHNfbWFrZV9lcnJvciAocmV0KTsNCkBAIC04ODMsNiArMTA5Nyw5IEBADQogew0KICAg Z251dGxzX2dsb2JhbF9pbml0aWFsaXplZCA9IDA7DQogDQorICBRZ251dGxzX2RsbCA9IGludGVy bl9jX3N0cmluZyAoImdudXRscyIpOw0KKyAgc3RhdGljcHJvICgmUWdudXRsc19kbGwpOw0KKw0K ICAgUWdudXRsc19sb2dfbGV2ZWwgPSBpbnRlcm5fY19zdHJpbmcgKCJnbnV0bHMtbG9nLWxldmVs Iik7DQogICBzdGF0aWNwcm8gKCZRZ251dGxzX2xvZ19sZXZlbCk7DQogDQpAQCAtOTU2LDYgKzEx NzMsNyBAQA0KICAgZGVmc3ViciAoJlNnbnV0bHNfYm9vdCk7DQogICBkZWZzdWJyICgmU2dudXRs c19kZWluaXQpOw0KICAgZGVmc3ViciAoJlNnbnV0bHNfYnllKTsNCisgIGRlZnN1YnIgKCZTZ251 dGxzX2F2YWlsYWJsZV9wKTsNCiB9DQogDQogI2VuZGlmIC8qIEhBVkVfR05VVExTICovDQoNCj09 PSBtb2RpZmllZCBmaWxlICdzcmMvZ251dGxzLmgnDQotLS0gc3JjL2dudXRscy5oCTIwMTEtMDQt MjUgMDE6MzA6NTEgKzAwMDANCisrKyB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2UgdGhlDQorICAgaGFuZGxlIGlzIG5vdCBy ZWNvcmRlZCBhbnl3aGVyZSwgYW5kIHNvIGlzIGxvc3QgYWZ0ZXIgdXNlKS4gIEl0DQorICAgd291 bGQgYmUgdHJpdmlhbCB0byBzYXZlIHRoZSBoYW5kbGUgdG9vIGluIDpsb2FkZWQtZnJvbSwgYnV0 DQorICAgY3VycmVudGx5IHRoZXJlJ3Mgbm8gdXNlIGNhc2UgZm9yIGl0LiAgKi8NCitITU9EVUxF DQordzMyX2RlbGF5ZWRfbG9hZCAoTGlzcF9PYmplY3QgbGlicmFyaWVzLCBMaXNwX09iamVjdCBs aWJyYXJ5X2lkKQ0KK3sNCisgIEhNT0RVTEUgbGlicmFyeV9kbGwgPSBOVUxMOw0KKw0KKyAgQ0hF Q0tfU1lNQk9MIChsaWJyYXJ5X2lkKTsNCisNCisgIGlmIChDT05TUCAobGlicmFyaWVzKSAmJiBO SUxQIChGYXNzcSAobGlicmFyeV9pZCwgVmxpYnJhcnlfY2FjaGUpKSkNCisgICAgew0KKyAgICAg IExpc3BfT2JqZWN0IGZvdW5kID0gUW5pbDsNCisgICAgICBMaXNwX09iamVjdCBkbGxzID0gRmFz c3EgKGxpYnJhcnlfaWQsIGxpYnJhcmllcyk7DQorDQorICAgICAgaWYgKENPTlNQIChkbGxzKSkN CisgICAgICAgIGZvciAoZGxscyA9IFhDRFIgKGRsbHMpOyBDT05TUCAoZGxscyk7IGRsbHMgPSBY Q0RSIChkbGxzKSkNCisgICAgICAgICAgew0KKyAgICAgICAgICAgIENIRUNLX1NUUklOR19DQVIg KGRsbHMpOw0KKyAgICAgICAgICAgIGlmIChsaWJyYXJ5X2RsbCA9IExvYWRMaWJyYXJ5IChTREFU QSAoWENBUiAoZGxscykpKSkNCisgICAgICAgICAgICAgIHsNCisgICAgICAgICAgICAgICAgZm91 bmQgPSBYQ0FSIChkbGxzKTsNCisgICAgICAgICAgICAgICAgYnJlYWs7DQorICAgICAgICAgICAg ICB9DQorICAgIC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