From: Mario Limonciello <mario_limonciello@dell.com>
To: "grub-devel@gnu.org" <grub-devel@gnu.org>
Subject: [PATCH 2/3] Use _fullpath instead of realpath on mingw32
Date: Wed, 21 Sep 2011 15:49:25 -0500 [thread overview]
Message-ID: <4E7A4DD5.3070300@dell.com> (raw)
[-- Attachment #1: Type: text/plain, Size: 924 bytes --]
=== modified file 'ChangeLog'
--- ChangeLog 2011-09-21 20:36:50 +0000
+++ ChangeLog 2011-09-21 20:38:06 +0000
@@ -1,6 +1,7 @@
2011-09-21 Mario Limonciello <mario_limonciello@dell.com>
* Remove extra declaration of sleep for mingw32.
+ * No realpath on mingw32. Instead use _fullpath.
2011-09-17 Grégoire Sutre <gregoire.sutre@gmail.com>
=== modified file 'grub-core/kern/emu/misc.c'
--- grub-core/kern/emu/misc.c 2011-07-08 11:33:12 +0000
+++ grub-core/kern/emu/misc.c 2011-09-21 20:38:06 +0000
@@ -224,6 +224,11 @@
canonicalize_file_name (const char *path)
{
char *ret;
+#ifdef __MINGW32__
+ ret = xmalloc(PATH_MAX);
+ if (!_fullpath(ret, path, PATH_MAX))
+ return NULL;
+#else
#ifdef PATH_MAX
ret = xmalloc (PATH_MAX);
if (!realpath (path, ret))
@@ -231,6 +236,7 @@
#else
ret = realpath (path, NULL);
#endif
+#endif /* __MINGW32__ */
return ret;
}
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: ml_3426.patch --]
[-- Type: text/x-diff; name="ml_3426.patch", Size: 895 bytes --]
=== modified file 'ChangeLog'
--- ChangeLog 2011-09-21 20:36:50 +0000
+++ ChangeLog 2011-09-21 20:38:06 +0000
@@ -1,6 +1,7 @@
2011-09-21 Mario Limonciello <mario_limonciello@dell.com>
* Remove extra declaration of sleep for mingw32.
+ * No realpath on mingw32. Instead use _fullpath.
2011-09-17 Grégoire Sutre <gregoire.sutre@gmail.com>
=== modified file 'grub-core/kern/emu/misc.c'
--- grub-core/kern/emu/misc.c 2011-07-08 11:33:12 +0000
+++ grub-core/kern/emu/misc.c 2011-09-21 20:38:06 +0000
@@ -224,6 +224,11 @@
canonicalize_file_name (const char *path)
{
char *ret;
+#ifdef __MINGW32__
+ ret = xmalloc(PATH_MAX);
+ if (!_fullpath(ret, path, PATH_MAX))
+ return NULL;
+#else
#ifdef PATH_MAX
ret = xmalloc (PATH_MAX);
if (!realpath (path, ret))
@@ -231,6 +236,7 @@
#else
ret = realpath (path, NULL);
#endif
+#endif /* __MINGW32__ */
return ret;
}
next reply other threads:[~2011-09-21 20:49 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-09-21 20:49 Mario Limonciello [this message]
2011-09-29 8:37 ` [PATCH 2/3] Use _fullpath instead of realpath on mingw32 Vladimir 'φ-coder/phcoder' Serbinenko
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=4E7A4DD5.3070300@dell.com \
--to=mario_limonciello@dell.com \
--cc=grub-devel@gnu.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
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.