ALT Linux Sisyphus discussions
 help / color / mirror / Atom feed
From: Alexey Morozov <morozov@novosoft.ru>
To: Sisyphus Mailing list <sisyphus@altlinux.ru>
Cc: Sergey V Turchin <zerg@altlinux.ru>
Subject: [sisyphus] Разборки с menu
Date: 02 Apr 2002 17:50:36 +0700
Message-ID: <1017744636.2265.472.camel@sig.novosoft.ru> (raw)

[-- Attachment #1: Type: text/plain, Size: 372 bytes --]

Ну, я тут покопался с menu (уф-ф-ф, то ли я чего-то не понимаю, то ли
проектирование в проекте было никаким), набрел на причину моих давешних
ужасов с "iconv ... failed...". Патч в аттачменте. Сдается мне, кто-то
невнимательно читал доки на iconv или я не понял, что хотели сказать (но
в итоге, то, что сказали - все равно ошибочно. Как оно вообще
работало-то?)



[-- Attachment #2: menu-2.1.5-iconv.patch --]
[-- Type: text/x-patch, Size: 771 bytes --]

diff -urN menu-2.1.5.orig/install-menu/install-menu.cc menu-2.1.5/install-menu/install-menu.cc
--- menu-2.1.5.orig/install-menu/install-menu.cc	Tue Apr  2 17:31:16 2002
+++ menu-2.1.5/install-menu/install-menu.cc	Tue Apr  2 17:37:44 2002
@@ -810,8 +810,11 @@
   size_t destlen = sizeof(buf) - 1;
   char *tmp = buf;
 
-  if ( iconv(iconvcontext, (char**)&start, &srclen, &tmp, &destlen) < text.length() )
-    cerr << "iconv from " << from << " to " << to << " failed for: " << text << endl;
+  if ( iconv(iconvcontext, (char**)&start, &srclen, &tmp, &destlen) == (size_t)-1 )
+    cerr << "iconv from " << from << " to " << to 
+	 << " failed for: " << text
+	 << " (" << strerror(errno) << ')'
+	 << endl;
 
   iconv_close(iconvcontext);
   *tmp='\0';

             reply	other threads:[~2002-04-02 10:50 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-04-02 10:50 Alexey Morozov [this message]
2002-04-02 11:57 ` Anton B. Farygin
2002-04-02 13:03 ` Dmitry V. Levin

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1017744636.2265.472.camel@sig.novosoft.ru \
    --to=morozov@novosoft.ru \
    --cc=sisyphus@altlinux.ru \
    --cc=zerg@altlinux.ru \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

ALT Linux Sisyphus discussions

This inbox may be cloned and mirrored by anyone:

	git clone --mirror http://lore.altlinux.org/sisyphus/0 sisyphus/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 sisyphus sisyphus/ http://lore.altlinux.org/sisyphus \
		sisyphus@altlinux.ru sisyphus@altlinux.org sisyphus@lists.altlinux.org sisyphus@lists.altlinux.ru sisyphus@lists.altlinux.com sisyphus@linuxteam.iplabs.ru sisyphus@list.linux-os.ru
	public-inbox-index sisyphus

Example config snippet for mirrors.
Newsgroup available over NNTP:
	nntp://lore.altlinux.org/org.altlinux.lists.sisyphus


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git