checksubprocerr(status,description,sigpipeok);
}
-typedef void (*do_fd_write_t)(char *, int, char *, void *data);
typedef struct do_fd_copy_data {
int fd;
} do_fd_copy_data_t;
typedef struct do_fd_buf_data {
- char *buf;
+ void *buf;
+ int type;
} do_fd_buf_data_t;
-int do_fd_write_fd(char* buf, int length, void *proc_data, char *desc) {
- do_fd_copy_data_t *data = (do_fd_copy_data_t *)proc_data;
- if(write(data->fd, buf, length) < length)
- ohshite(_("failed in do_fd_write_fd (%s)"), desc);
-}
-
-int do_fd_copy(int fd1, int fd2, int limit, char *desc, ...) {
- do_fd_copy_data_t data = { fd2 };
- va_list al;
- struct varbuf v;
-
- varbufinit(&v);
-
- va_start(al,desc);
- varbufvprintf(&v, desc, al);
- va_end(al);
-
- do_fd_read(fd1, limit, do_fd_write_fd, &data, v.buf);
- varbuffree(&v);
-}
-
-int do_fd_write_buf(char *buf, int length, void *proc_data, char *desc) {
+void do_fd_write_combined(char *buf, int length, void *proc_data, char *desc) {
do_fd_buf_data_t *data = (do_fd_buf_data_t *)proc_data;
- memcpy(data->buf, buf, length);
- data->buf += length;
+ switch(data->type) {
+ case FD_WRITE_BUF:
+ memcpy(data->buf, buf, length);
+ data->buf += length;
+ break;
+ case FD_WRITE_VBUF:
+ varbufaddbuf((struct varbuf *)data->buf, buf, length);
+ data->buf += length;
+ break;
+ case FD_WRITE_FD:
+ if(write((int)data->buf, buf, length) < length)
+ ohshite(_("failed in do_fd_write_combined (%i, %s)"), FD_WRITE_FD, desc);
+ break;
+ default:
+ fprintf(stderr, _("unknown data type `%i' in do_fd_write_buf\n"), data->type);
+ }
}
-int read_fd_into_buf(int fd, char *buf, int limit, char *desc, ...) {
- do_fd_buf_data_t data = { buf };
+int read_fd_combined(int fd, void *buf, int type, int limit, char *desc, ...) {
+ do_fd_buf_data_t data = { buf, type };
va_list al;
struct varbuf v;
varbufvprintf(&v, desc, al);
va_end(al);
- do_fd_read(fd, limit, do_fd_write_buf, &data, v.buf);
+ do_fd_read(fd, limit, do_fd_write_combined, &data, v.buf);
varbuffree(&v);
}
+
int do_fd_read(int fd1, int limit, do_fd_write_t write_proc, void *proc_data, char *desc) {
char *buf;
int count, bufsize= 32768, bytesread= 0;
msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
-"POT-Creation-Date: 2000-12-04 01:13+0100\n"
+"POT-Creation-Date: 2000-12-09 03:03+0100\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
msgid "wait for %s failed"
msgstr ""
-#: lib/mlib.c:137
+#: lib/mlib.c:138
#, c-format
msgid "failed in do_fd_write_fd (%s)"
msgstr ""
-#: lib/mlib.c:142
-msgid "failed in do_fd_write_fd"
-msgstr ""
-
-#: lib/mlib.c:195
+#: lib/mlib.c:183
#, c-format
msgid "failed to allocate buffer in do_fd_read (%s)"
msgstr ""
-#: lib/mlib.c:215
+#: lib/mlib.c:202
#, c-format
msgid "failed in do_fd_read on read (%s)"
msgstr ""
msgid "--forget-old-unavail takes no arguments"
msgstr ""
-#: dpkg-deb/build.c:63
+#: dpkg-deb/build.c:66
#, c-format
msgid "dpkg-deb - error: %s (`%s') doesn't contain any digits\n"
msgstr ""
+#: dpkg-deb/build.c:164
+#, c-format
+msgid "%s: no compression copy loop"
+msgstr ""
+
+#: dpkg-deb/build.c:173
+#, c-format
+msgid "%s: internal gzip error: read: `%s'"
+msgstr ""
+
+#: dpkg-deb/build.c:183
+#, c-format
+msgid "%s: internal gzip error: write: `%s'"
+msgstr ""
+
+#: dpkg-deb/build.c:186
+#, c-format
+msgid "%s: internal gzip error: read(%i) != write(%i)"
+msgstr ""
+
+#: dpkg-deb/build.c:191
+#, c-format
+msgid "%s: failed to exec gzip %s"
+msgstr ""
+
#. Decode our arguments
-#: dpkg-deb/build.c:168
+#: dpkg-deb/build.c:220
msgid "--build needs a directory argument"
msgstr ""
-#: dpkg-deb/build.c:177
+#: dpkg-deb/build.c:229
msgid "--build takes at most two arguments"
msgstr ""
-#: dpkg-deb/build.c:181
+#: dpkg-deb/build.c:233
#, c-format
msgid "unable to check for existence of archive `%.250s'"
msgstr ""
-#: dpkg-deb/build.c:196
+#: dpkg-deb/build.c:248
msgid "target is directory - cannot skip control file check"
msgstr ""
-#: dpkg-deb/build.c:197
+#: dpkg-deb/build.c:249
#, c-format
msgid ""
"dpkg-deb: warning, not checking contents of control area.\n"
"dpkg-deb: building an unknown package in `%s'.\n"
msgstr ""
-#: dpkg-deb/build.c:215
+#: dpkg-deb/build.c:267
msgid "package name has characters that aren't lowercase alphanums or `-+.'"
msgstr ""
-#: dpkg-deb/build.c:217
+#: dpkg-deb/build.c:269
#, c-format
msgid "warning, `%s' contains user-defined Priority value `%s'\n"
msgstr ""
-#: dpkg-deb/build.c:222
+#: dpkg-deb/build.c:274
#, c-format
msgid "warning, `%s' contains user-defined field `%s'\n"
msgstr ""
-#: dpkg-deb/build.c:228
+#: dpkg-deb/build.c:280
#, c-format
msgid "%d errors in control file"
msgstr ""
-#: dpkg-deb/build.c:239
+#: dpkg-deb/build.c:291
#, c-format
msgid "dpkg-deb: building package `%s' in `%s'.\n"
msgstr ""
-#: dpkg-deb/build.c:247
+#: dpkg-deb/build.c:299
#, c-format
msgid "control directory has bad permissions %03lo (must be >=0755 and <=0775)"
msgstr ""
-#: dpkg-deb/build.c:258
+#: dpkg-deb/build.c:310
#, c-format
msgid "maintainer script `%.50s' is not a plain file or symlink"
msgstr ""
-#: dpkg-deb/build.c:260
+#: dpkg-deb/build.c:312
#, c-format
msgid ""
"maintainer script `%.50s' has bad permissions %03lo (must be >=0555 and "
"<=0775)"
msgstr ""
-#: dpkg-deb/build.c:264
+#: dpkg-deb/build.c:316
#, c-format
msgid "maintainer script `%.50s' is not stattable"
msgstr ""
-#: dpkg-deb/build.c:274
+#: dpkg-deb/build.c:326
msgid "empty string from fgets reading conffiles"
msgstr ""
-#: dpkg-deb/build.c:276
+#: dpkg-deb/build.c:328
#, c-format
msgid ""
"warning, conffile name `%.50s...' is too long, or missing final newline\n"
msgstr ""
-#: dpkg-deb/build.c:288
+#: dpkg-deb/build.c:340
#, c-format
msgid "conffile `%.250s' does not appear in package"
msgstr ""
-#: dpkg-deb/build.c:290
+#: dpkg-deb/build.c:342
#, c-format
msgid "conffile `%.250s' is not stattable"
msgstr ""
-#: dpkg-deb/build.c:292
+#: dpkg-deb/build.c:344
#, c-format
msgid "warning, conffile `%s' is not a plain file\n"
msgstr ""
-#: dpkg-deb/build.c:297
+#: dpkg-deb/build.c:349
msgid "error reading conffiles file"
msgstr ""
-#: dpkg-deb/build.c:300
+#: dpkg-deb/build.c:352
msgid "error opening conffiles file"
msgstr ""
-#: dpkg-deb/build.c:303
+#: dpkg-deb/build.c:355
#, c-format
msgid "dpkg-deb: ignoring %d warnings about the control file(s)\n"
msgstr ""
#. Now that we have verified everything its time to actually
#. * build something. Lets start by making the ar-wrapper.
#.
-#: dpkg-deb/build.c:312
+#: dpkg-deb/build.c:364
#, c-format
msgid "unable to create `%.255s'"
msgstr ""
-#: dpkg-deb/build.c:313
+#: dpkg-deb/build.c:365
#, c-format
msgid "unable to unbuffer `%.255s'"
msgstr ""
-#: dpkg-deb/build.c:318 dpkg-deb/build.c:390 dpkg-deb/build.c:410
+#: dpkg-deb/build.c:370 dpkg-deb/build.c:443 dpkg-deb/build.c:465
#, c-format
msgid "failed to chdir to `%.255s'"
msgstr ""
-#: dpkg-deb/build.c:319
+#: dpkg-deb/build.c:371
msgid "failed to chdir to .../DEBIAN"
msgstr ""
-#: dpkg-deb/build.c:320 dpkg-deb/build.c:412
+#: dpkg-deb/build.c:372 dpkg-deb/build.c:445
msgid "failed to exec tar -cf"
msgstr ""
#. Create a temporary file to store the control data in. Immediately unlink
#. * our temporary file so others can't mess with it.
#.
-#: dpkg-deb/build.c:326
+#: dpkg-deb/build.c:378
msgid "failed to make tmpfile (control)"
msgstr ""
-#: dpkg-deb/build.c:327
+#: dpkg-deb/build.c:379
#, c-format
msgid "failed to open tmpfile (control), %s"
msgstr ""
#. make sure it's gone, the fd will remain until we close it
-#: dpkg-deb/build.c:330
+#: dpkg-deb/build.c:382
#, c-format
msgid "failed to unlink tmpfile (control), %s"
msgstr ""
-#: dpkg-deb/build.c:338
-msgid "failed to exec gzip -9c"
+#: dpkg-deb/build.c:390 dpkg-deb/build.c:419 dpkg-deb/build.c:455
+msgid "control"
msgstr ""
-#: dpkg-deb/build.c:343
+#: dpkg-deb/build.c:395
msgid "failed to fstat tmpfile (control)"
msgstr ""
-#: dpkg-deb/build.c:366
+#: dpkg-deb/build.c:418
msgid "failed to rewind tmpfile (control)"
msgstr ""
-#: dpkg-deb/build.c:367
-msgid "control"
-msgstr ""
-
-#: dpkg-deb/build.c:374
+#: dpkg-deb/build.c:426
msgid "failed to make tmpfile (data)"
msgstr ""
-#: dpkg-deb/build.c:375
+#: dpkg-deb/build.c:427
#, c-format
msgid "failed to open tmpfile (data), %s"
msgstr ""
#. make sure it's gone, the fd will remain until we close it
-#: dpkg-deb/build.c:378
+#: dpkg-deb/build.c:430
#, c-format
msgid "failed to unlink tmpfile (data), %s"
msgstr ""
-#: dpkg-deb/build.c:392
+#: dpkg-deb/build.c:467
msgid "failed to exec find"
msgstr ""
-#: dpkg-deb/build.c:425
-msgid "no compression copy loop"
-msgstr ""
-
-#: dpkg-deb/build.c:431
-#, c-format
-msgid "failed to exec gzip %s from tar -cf"
-msgstr ""
-
-#: dpkg-deb/build.c:437 dpkg-deb/build.c:440
+#: dpkg-deb/build.c:478 dpkg-deb/build.c:485
msgid "failed to write filename to tar pipe (data)"
msgstr ""
-#: dpkg-deb/build.c:458
+#: dpkg-deb/build.c:502
msgid "failed to rewind tmpfile (data)"
msgstr ""
-#: dpkg-deb/build.c:459
+#: dpkg-deb/build.c:503
msgid "cat (data)"
msgstr ""
-#: dpkg-deb/extract.c:48
+#: dpkg-deb/extract.c:51
msgid "failed to exec sh -c mv foo/* &c"
msgstr ""
-#: dpkg-deb/extract.c:55
+#: dpkg-deb/extract.c:58
#, c-format
msgid "error reading %s from %.255s"
msgstr ""
-#: dpkg-deb/extract.c:57
+#: dpkg-deb/extract.c:60
#, c-format
msgid "unexpected end of file in %s in %.255s"
msgstr ""
-#: dpkg-deb/extract.c:68 split/info.c:52
+#: dpkg-deb/extract.c:71 split/info.c:52
#, c-format
msgid "file `%.250s' is corrupt - %.250s length contains nulls"
msgstr ""
-#: dpkg-deb/extract.c:75 split/info.c:43
+#: dpkg-deb/extract.c:78 split/info.c:43
#, c-format
msgid "file `%.250s' is corrupt - bad digit (code %d) in %s"
msgstr ""
-#: dpkg-deb/extract.c:84
+#: dpkg-deb/extract.c:87
msgid "skipped member data"
msgstr ""
-#: dpkg-deb/extract.c:109
+#: dpkg-deb/extract.c:118
#, c-format
msgid "failed to read archive `%.255s'"
msgstr ""
-#: dpkg-deb/extract.c:110
+#: dpkg-deb/extract.c:119
msgid "failed to fstat archive"
msgstr ""
-#: dpkg-deb/extract.c:111
+#: dpkg-deb/extract.c:120
msgid "version number"
msgstr ""
-#: dpkg-deb/extract.c:120
+#: dpkg-deb/extract.c:129
msgid "between members"
msgstr ""
-#: dpkg-deb/extract.c:122 split/info.c:94
+#: dpkg-deb/extract.c:131 split/info.c:94
#, c-format
msgid "file `%.250s' is corrupt - bad magic at end of first header"
msgstr ""
-#: dpkg-deb/extract.c:126
+#: dpkg-deb/extract.c:135
#, c-format
msgid "file `%.250s' is corrupt - negative member length %ld"
msgstr ""
-#: dpkg-deb/extract.c:130
+#: dpkg-deb/extract.c:139
#, c-format
msgid "file `%.250s' is not a debian binary archive (try dpkg-split?)"
msgstr ""
-#: dpkg-deb/extract.c:133
+#: dpkg-deb/extract.c:142
msgid "header info member"
msgstr ""
-#: dpkg-deb/extract.c:136
+#: dpkg-deb/extract.c:145
msgid "archive has no newlines in header"
msgstr ""
-#: dpkg-deb/extract.c:139
+#: dpkg-deb/extract.c:148
msgid "archive has no dot in version number"
msgstr ""
-#: dpkg-deb/extract.c:142
+#: dpkg-deb/extract.c:151
#, c-format
msgid "archive version %.250s not understood, get newer dpkg-deb"
msgstr ""
-#: dpkg-deb/extract.c:160
+#: dpkg-deb/extract.c:169
#, c-format
msgid "file `%.250s' contains ununderstood data member %.*s, giving up"
msgstr ""
-#: dpkg-deb/extract.c:165
+#: dpkg-deb/extract.c:174
#, c-format
msgid "file `%.250s' contains two control members, giving up"
msgstr ""
-#: dpkg-deb/extract.c:177
+#: dpkg-deb/extract.c:186
#, c-format
msgid ""
" new debian package, version %s.\n"
" size %ld bytes: control archive= %ld bytes.\n"
msgstr ""
-#: dpkg-deb/extract.c:189
+#: dpkg-deb/extract.c:198
msgid "ctrl information length"
msgstr ""
-#: dpkg-deb/extract.c:191
+#: dpkg-deb/extract.c:200
#, c-format
msgid "archive has malformatted ctrl len `%s'"
msgstr ""
-#: dpkg-deb/extract.c:194
+#: dpkg-deb/extract.c:203
#, c-format
msgid ""
" old debian package, version %s.\n"
" size %ld bytes: control archive= %ld, main archive= %ld.\n"
msgstr ""
-#: dpkg-deb/extract.c:203
+#: dpkg-deb/extract.c:212
msgid "ctrlarea"
msgstr ""
-#: dpkg-deb/extract.c:209
+#: dpkg-deb/extract.c:218
msgid ""
"dpkg-deb: file looks like it might be an archive which has been\n"
"dpkg-deb: corrupted by being downloaded in ASCII mode\n"
msgstr ""
-#: dpkg-deb/extract.c:214
+#: dpkg-deb/extract.c:223
#, c-format
msgid "`%.255s' is not a debian format archive"
msgstr ""
-#: dpkg-deb/extract.c:219
+#: dpkg-deb/extract.c:228
msgid "fgetpos failed"
msgstr ""
-#: dpkg-deb/extract.c:223
+#: dpkg-deb/extract.c:232
msgid "fsetpos failed"
msgstr ""
-#: dpkg-deb/extract.c:230
+#: dpkg-deb/extract.c:239
msgid "failed to fdopen p1 in paste"
msgstr ""
-#: dpkg-deb/extract.c:232
+#: dpkg-deb/extract.c:241
msgid "failed to write to gzip -dc"
msgstr ""
-#: dpkg-deb/extract.c:233
+#: dpkg-deb/extract.c:242
msgid "failed to close gzip -dc"
msgstr ""
-#: dpkg-deb/extract.c:240
+#: dpkg-deb/extract.c:249
msgid "failed to syscall lseek to files archive portion"
msgstr ""
-#: dpkg-deb/extract.c:248
+#: dpkg-deb/extract.c:257
msgid "failed to write to pipe in copy"
msgstr ""
-#: dpkg-deb/extract.c:249
+#: dpkg-deb/extract.c:258
msgid "failed to close pipe in copy"
msgstr ""
-#: dpkg-deb/extract.c:262
+#: dpkg-deb/extract.c:281
+#, c-format
+msgid "internal gzip error: `%s'"
+msgstr ""
+
+#: dpkg-deb/extract.c:287
msgid "failed to exec gzip -dc"
msgstr ""
-#: dpkg-deb/extract.c:270
+#: dpkg-deb/extract.c:296
msgid "failed to create directory"
msgstr ""
-#: dpkg-deb/extract.c:271
+#: dpkg-deb/extract.c:297
msgid "failed to chdir to directory after creating it"
msgstr ""
-#: dpkg-deb/extract.c:273
+#: dpkg-deb/extract.c:299
msgid "failed to chdir to directory"
msgstr ""
-#: dpkg-deb/extract.c:287
+#: dpkg-deb/extract.c:313
msgid "failed to exec tar"
msgstr ""
-#: dpkg-deb/extract.c:310 dpkg-deb/extract.c:325 dpkg-deb/info.c:66
+#: dpkg-deb/extract.c:336 dpkg-deb/extract.c:351 dpkg-deb/info.c:66
#, c-format
msgid "--%s needs a .deb filename argument"
msgstr ""
-#: dpkg-deb/extract.c:313
+#: dpkg-deb/extract.c:339
#, c-format
msgid ""
"--%s needs a target directory.\n"
"Perhaps you should be using dpkg --install ?"
msgstr ""
-#: dpkg-deb/extract.c:316
+#: dpkg-deb/extract.c:342
#, c-format
msgid "--%s takes at most two arguments (.deb and directory)"
msgstr ""
-#: dpkg-deb/extract.c:327
+#: dpkg-deb/extract.c:353
#, c-format
msgid "--%s takes only one argument (.deb filename)"
msgstr ""