Gentoo Archives: gentoo-commits

From: "Wulf Krueger (philantrop)" <philantrop@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in app-pda/jpilot/files: jpilot-0.99.9-keyring-cats.patch digest-jpilot-0.99.9 digest-jpilot-0.99.8-r1 jpilot-0.99.8-glob.patch jpilot-0.99.8-glibc-free.patch digest-jpilot-0.99.8_pre9 jpilot-0.99.8-memory.patch digest-jpilot-0.99.8
Date: Mon, 17 Sep 2007 05:46:19
Message-Id: E1IX9Jd-0000nX-UN@stork.gentoo.org
1 philantrop 07/09/17 05:38:37
2
3 Added: jpilot-0.99.9-keyring-cats.patch
4 digest-jpilot-0.99.9
5 Removed: digest-jpilot-0.99.8-r1 jpilot-0.99.8-glob.patch
6 jpilot-0.99.8-glibc-free.patch
7 digest-jpilot-0.99.8_pre9
8 jpilot-0.99.8-memory.patch digest-jpilot-0.99.8
9 Log:
10 Version bump to 0.99.9 with several fixes. Removed obsolete versions.
11 Fixes bugs 93471, 128076, 148440 and 160349.
12 Thanks to (in order of appearance) Craig Lawson, Mark Wagner, Serhij S. Stasyuk and Thomas Jost for their contributions!
13 (Portage version: 2.1.3.9)
14
15 Revision Changes Path
16 1.1 app-pda/jpilot/files/jpilot-0.99.9-keyring-cats.patch
17
18 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/app-pda/jpilot/files/jpilot-0.99.9-keyring-cats.patch?rev=1.1&view=markup
19 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/app-pda/jpilot/files/jpilot-0.99.9-keyring-cats.patch?rev=1.1&content-type=text/plain
20
21 Index: jpilot-0.99.9-keyring-cats.patch
22 ===================================================================
23 --- KeyRing/keyring.c.original 2006-06-24 21:49:51.000000000 -0700
24 +++ KeyRing/keyring.c 2006-12-17 20:02:08.000000000 -0800
25 @@ -160,6 +160,8 @@
26
27 static int keyring_find(int unique_id);
28
29 +int plugin_unpack_cai_from_ai(struct CategoryAppInfo *cai, unsigned char *ai_raw, int len);
30 +
31 /****************************** Main Code *************************************/
32 static int pack_KeyRing(struct KeyRing *kr, unsigned char *buf, int buf_size,
33 int *wrote_size)
34 @@ -1348,17 +1350,12 @@
35
36 /* This gets the application specific data out of the database for us.
37 * We still need to write a function to unpack it from its blob form. */
38 +
39 + memset (&ai, 0, sizeof (ai));
40
41 jp_get_app_info("Keys-Gtkr", &buf, &buf_size);
42
43 - /* This call should work, but the appinfo is too small, so we do it */
44 - /* Keyring is not using a legal category app info structure */
45 - /* unpack_CategoryAppInfo(&ai, buf, buf_size+4); */
46 -
47 - /* I'm going to be lazy and only get the names, since that's all I use */
48 - for (i=0; i<NUM_KEYRING_CAT_ITEMS; i++) {
49 - memcpy(&ai.name[i][0], buf+i*16+2, 16);
50 - }
51 + plugin_unpack_cai_from_ai (&ai, buf, buf_size);
52
53 free(buf);
54
55 @@ -2238,3 +2235,62 @@
56
57 return EXIT_SUCCESS;
58 }
59 +
60 +/* Stolen from pilot-link and modified slightly. */
61 +int plugin_unpack_cai_from_ai(struct CategoryAppInfo *ai, unsigned char *record, int len)
62 +{
63 + int i, rec;
64 +
65 + if (len < 2 + 16 * 16 + 16 + 2)
66 + return 0;
67 + rec = get_short(record);
68 + for (i = 0; i < 16; i++) {
69 + if (rec & (1 << i))
70 + ai->renamed[i] = 1;
71 + else
72 + ai->renamed[i] = 0;
73 + }
74 + record += 2;
75 + for (i = 0; i < 16; i++) {
76 + memcpy(ai->name[i], record, 16);
77 + record += 16;
78 + }
79 + memcpy(ai->ID, record, 16);
80 + record += 16;
81 + ai->lastUniqueID = get_byte(record);
82 + record += 2;
83 +
84 + return 2 + 16 * 16 + 16 + 2;
85 +}
86 +
87 +int plugin_pack_cai_into_ai(struct CategoryAppInfo *ai, unsigned char *record, int len)
88 +{
89 + int i, rec;
90 +
91 + unsigned char *start = record;
92 +
93 + if (!record) {
94 + return 2 + 16 * 16 + 16 + 2;
95 + }
96 + if (len < (2 + 16 * 16 + 16 + 2))
97 + return 0; /* not enough room */
98 + rec = 0;
99 + for (i = 0; i < 16; i++) {
100 + if (ai->renamed[i])
101 + rec |= (1 << i);
102 + }
103 + set_short(record, rec);
104 + record += 2;
105 + for (i = 0; i < 16; i++) {
106 + memcpy(record, ai->name[i], 16);
107 + record += 16;
108 + }
109 + memcpy(record, ai->ID, 16);
110 + record += 16;
111 + set_byte(record, ai->lastUniqueID);
112 + record++;
113 + set_byte(record, 0); /* gapfill */
114 + record++;
115 +
116 + return (record - start);
117 +}
118
119
120
121 1.1 app-pda/jpilot/files/digest-jpilot-0.99.9
122
123 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/app-pda/jpilot/files/digest-jpilot-0.99.9?rev=1.1&view=markup
124 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/app-pda/jpilot/files/digest-jpilot-0.99.9?rev=1.1&content-type=text/plain
125
126 Index: digest-jpilot-0.99.9
127 ===================================================================
128 MD5 c39df29aeed57b84a674524856ebc290 jpilot-0.99.9.tar.gz 1671351
129 RMD160 0286b9f9579dbbdb8e9bd207384561814bab5114 jpilot-0.99.9.tar.gz 1671351
130 SHA256 341491ad727e234b58c7d5f057bcff363d15d2f223c1beab05fc49820dfe6432 jpilot-0.99.9.tar.gz 1671351
131
132
133
134 --
135 gentoo-commits@g.o mailing list