From: Alexey Tourbin <at@altlinux.ru> To: ALT Devel discussion list <devel@altlinux.org> Subject: [devel] Re: RPM::Database Date: Wed, 19 Oct 2005 23:07:02 +0400 Message-ID: <20051019190702.GV7934@solemn.turbinal.org> (raw) In-Reply-To: <20051019180400.GA9383@basalt.office.altlinux.org> [-- Attachment #1: Type: text/plain, Size: 1146 bytes --] On Wed, Oct 19, 2005 at 10:04:00PM +0400, Dmitry V. Levin wrote: > On Wed, Oct 19, 2005 at 09:46:29PM +0400, Alexey Tourbin wrote: > > Такое впечатление, что происходит неправильный dereferencing, то есть > > rpmTagTable в качестве указателя уже смотрит непойми куда. Я озадачен. :) > > Это просто: > > 1. extern const struct headerTagTableEntry_s rpmTagTable[]; > Что такое символ rpmTagTable для приложения? > Это адрес, по которому находится первый элемент массива. Да. > 2. extern const struct headerTagTableEntry_s * rpmTagTable; > Что такое символ rpmTagTable для приложения? > Это адрес, по которому находится адрес первого элемента массива. Нет. И тот и другой -- адрес первого элемента массива. Только первый адрес константный, его нельзя менять (компилятор сразу может проставить сам этот адрес в код, но не проставляет). А второй адрес можно менять, компилятор обязан использовать косвенную адресацию. Впрочем, я не до конца понимаю, что там делает компилятор. С точки зрения самого языка Си эти две записи идентичны. Нужно посмотреть, что там `gcc -S' показывает, но лень. Но может посмотрю. :) [-- Attachment #2: Type: application/pgp-signature, Size: 189 bytes --]
prev parent reply other threads:[~2005-10-19 19:07 UTC|newest] Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top 2005-10-18 23:30 [devel] RPM::Database Alexey Tourbin 2005-10-19 9:05 ` Dmitry V. Levin 2005-10-19 13:01 ` [devel] RPM::Database Alexey Tourbin 2005-10-19 13:29 ` Dmitry V. Levin 2005-10-19 14:00 ` Alexey Tourbin 2005-10-19 13:56 ` Alexey Tourbin 2005-10-19 14:06 ` Dmitry V. Levin 2005-10-19 14:18 ` Alexey Tourbin 2005-10-19 15:50 ` Alexey Tourbin 2005-10-19 17:17 ` Dmitry V. Levin 2005-10-19 17:23 ` Alexey Tourbin 2005-10-19 17:43 ` Dmitry V. Levin 2005-10-19 17:46 ` Alexey Tourbin 2005-10-19 18:00 ` Alexey Tourbin 2005-10-19 18:04 ` Dmitry V. Levin 2005-10-19 19:07 ` Alexey Tourbin [this message]
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=20051019190702.GV7934@solemn.turbinal.org \ --to=at@altlinux.ru \ --cc=devel@altlinux.org \ --cc=devel@lists.altlinux.org \ /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 Team development discussions This inbox may be cloned and mirrored by anyone: git clone --mirror http://lore.altlinux.org/devel/0 devel/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 devel devel/ http://lore.altlinux.org/devel \ devel@altlinux.org devel@altlinux.ru devel@lists.altlinux.org devel@lists.altlinux.ru devel@linux.iplabs.ru mandrake-russian@linuxteam.iplabs.ru sisyphus@linuxteam.iplabs.ru public-inbox-index devel Example config snippet for mirrors. Newsgroup available over NNTP: nntp://lore.altlinux.org/org.altlinux.lists.devel AGPL code for this site: git clone https://public-inbox.org/public-inbox.git