From: Dubrovskiy Viacheslav <slava@tangramltd.com>
To: shigorin@gmail.com,
ALT Linux sysadmins' discussion <sysadmins@lists.altlinux.org>
Subject: Re: [Sysadmins] I: altlinux p6 branch openvz template caches online
Date: Sun, 25 Mar 2012 12:36:44 -0400
Message-ID: <4F6F499C.90907@tangramltd.com> (raw)
In-Reply-To: <20120325161404.GP18003@osdn.org.ua>
[-- Attachment #1: Type: text/plain, Size: 1583 bytes --]
25.03.2012 12:14, Michael Shigorin пишет:
>> Нужно или убрать или доделать
> Если убрать, будет опять неконсистентность в vps-download.
>
>> src/lib/create.c
>> 374 /* Store full ostemplate name */
>> 375 if (tmpl->ostmpl != NULL) {
>> 376 if (cmd_p->res.tmpl.ostmpl != NULL)
>> 377 free(cmd_p->res.tmpl.ostmpl);
>> 378 cmd_p->res.tmpl.ostmpl = strdup(tmpl->ostmpl);
>> 379 }
>>
>> Вот тут нужно через basename прогнать, чтобы сохранять не
>> полный путь, а только имя шаблона.
> Я уже опять боюсь трогать строки в сях после бэкпортирования
> propagator -- если бы не ldv@ и особенно gns@, был бы там и
> fd leak, и сегфолт.
>
> Хотелку внятно описать могу. :)
Кажется вот так правильно?
@@ -375,7 +376,7 @@ int vps_create(vps_handler *h, envid_t veid,
vps_param *vps_p, vps_param *cmd_p,
if (tmpl->ostmpl != NULL) {
if (cmd_p->res.tmpl.ostmpl != NULL)
free(cmd_p->res.tmpl.ostmpl);
- cmd_p->res.tmpl.ostmpl = strdup(tmpl->ostmpl);
+ cmd_p->res.tmpl.ostmpl = strdup(basename(tmpl->ostmpl));
}
if ((ret = vps_save_config(veid, dst, cmd_p, vps_p, action)))
goto err_names;
--
WBR,
Dubrovskiy Viacheslav
[-- Attachment #2: ÐÑипÑогÑаÑиÑеÑÐºÐ°Ñ Ð¿Ð¾Ð´Ð¿Ð¸ÑÑ S/MIME --]
[-- Type: application/pkcs7-signature, Size: 4903 bytes --]
next prev parent reply other threads:[~2012-03-25 16:36 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-03-22 17:21 Michael Shigorin
2012-03-22 19:26 ` Michael Shigorin
2012-03-25 4:59 ` Dubrovskiy Viacheslav
2012-03-25 8:51 ` Michael Shigorin
2012-03-25 15:09 ` Dubrovskiy Viacheslav
2012-03-25 16:14 ` Michael Shigorin
2012-03-25 16:36 ` Dubrovskiy Viacheslav [this message]
2012-03-25 16:51 ` Michael Shigorin
2012-03-25 17:01 ` Dubrovskiy Viacheslav
2012-03-25 17:30 ` Michael Shigorin
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=4F6F499C.90907@tangramltd.com \
--to=slava@tangramltd.com \
--cc=shigorin@gmail.com \
--cc=sysadmins@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 sysadmins discussion
This inbox may be cloned and mirrored by anyone:
git clone --mirror http://lore.altlinux.org/sysadmins/0 sysadmins/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 sysadmins sysadmins/ http://lore.altlinux.org/sysadmins \
sysadmins@lists.altlinux.org sysadmins@lists.altlinux.ru sysadmins@lists.altlinux.com
public-inbox-index sysadmins
Example config snippet for mirrors.
Newsgroup available over NNTP:
nntp://lore.altlinux.org/org.altlinux.lists.sysadmins
AGPL code for this site: git clone https://public-inbox.org/public-inbox.git