public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
* [PATCH] ShellPkg/cd: Do not print the destination dir when CD exits
@ 2017-01-26  4:34 Ruiyu Ni
  2017-01-26 14:51 ` Shah, Tapan
  2017-01-26 16:59 ` Carsey, Jaben
  0 siblings, 2 replies; 3+ messages in thread
From: Ruiyu Ni @ 2017-01-26  4:34 UTC (permalink / raw)
  To: edk2-devel; +Cc: Jaben Carsey, Chris J Phillips, Tapan Shah

Before the "cd fs0:dir" fix, CD only prints destination directory
when the destination contains ":".
However, the "cd fs0:dir" fix changed CD to always print destination
directory.

This patch changes CD to never print destination directory.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
Cc: Jaben Carsey <jaben.carsey@intel.com>
Cc: Chris J Phillips <chrisp@hpe.com>
Cc: Tapan Shah <tapandshah@hpe.com>
---
 ShellPkg/Library/UefiShellLevel2CommandsLib/Cd.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/ShellPkg/Library/UefiShellLevel2CommandsLib/Cd.c b/ShellPkg/Library/UefiShellLevel2CommandsLib/Cd.c
index d459a7a..dd4a740 100644
--- a/ShellPkg/Library/UefiShellLevel2CommandsLib/Cd.c
+++ b/ShellPkg/Library/UefiShellLevel2CommandsLib/Cd.c
@@ -3,7 +3,7 @@
 
   (C) Copyright 2016 Hewlett Packard Enterprise Development LP<BR>
   (C) Copyright 2015 Hewlett-Packard Development Company, L.P.<BR>
-  Copyright (c) 2009 - 2016, Intel Corporation. All rights reserved.<BR>
+  Copyright (c) 2009 - 2017, Intel Corporation. All rights reserved.<BR>
   This program and the accompanying materials
   are licensed and made available under the terms and conditions of the BSD License
   which accompanies this distribution.  The full text of the license may be found at
@@ -321,8 +321,6 @@ ShellCommandRunCd (
             if (EFI_ERROR (Status)) {
               ShellPrintHiiEx (-1, -1, NULL, STRING_TOKEN(STR_GEN_DIR_NF), gShellLevel2HiiHandle, L"cd", Param1Copy);
               ShellStatus = SHELL_NOT_FOUND;
-            } else {
-              ShellPrintHiiEx (-1, -1, NULL, STRING_TOKEN(STR_CD_PRINT), gShellLevel2HiiHandle, ShellGetCurrentDir(Drive));
             }
           }
         }
-- 
2.9.0.windows.1



^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] ShellPkg/cd: Do not print the destination dir when CD exits
  2017-01-26  4:34 [PATCH] ShellPkg/cd: Do not print the destination dir when CD exits Ruiyu Ni
@ 2017-01-26 14:51 ` Shah, Tapan
  2017-01-26 16:59 ` Carsey, Jaben
  1 sibling, 0 replies; 3+ messages in thread
From: Shah, Tapan @ 2017-01-26 14:51 UTC (permalink / raw)
  To: Ruiyu Ni, edk2-devel@lists.01.org
  Cc: Jaben Carsey, Phillips, Chris J (Plano, TX)

Reviewed-by: Tapan Shah <tapandshah@hpe.com>

-----Original Message-----
From: Ruiyu Ni [mailto:ruiyu.ni@intel.com] 
Sent: Wednesday, January 25, 2017 10:34 PM
To: edk2-devel@lists.01.org
Cc: Jaben Carsey <jaben.carsey@intel.com>; Phillips, Chris J (Plano, TX) <chrisp@hpe.com>; Shah, Tapan <tapandshah@hpe.com>
Subject: [PATCH] ShellPkg/cd: Do not print the destination dir when CD exits

Before the "cd fs0:dir" fix, CD only prints destination directory when the destination contains ":".
However, the "cd fs0:dir" fix changed CD to always print destination directory.

This patch changes CD to never print destination directory.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
Cc: Jaben Carsey <jaben.carsey@intel.com>
Cc: Chris J Phillips <chrisp@hpe.com>
Cc: Tapan Shah <tapandshah@hpe.com>
---
 ShellPkg/Library/UefiShellLevel2CommandsLib/Cd.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/ShellPkg/Library/UefiShellLevel2CommandsLib/Cd.c b/ShellPkg/Library/UefiShellLevel2CommandsLib/Cd.c
index d459a7a..dd4a740 100644
--- a/ShellPkg/Library/UefiShellLevel2CommandsLib/Cd.c
+++ b/ShellPkg/Library/UefiShellLevel2CommandsLib/Cd.c
@@ -3,7 +3,7 @@
 
   (C) Copyright 2016 Hewlett Packard Enterprise Development LP<BR>
   (C) Copyright 2015 Hewlett-Packard Development Company, L.P.<BR>
-  Copyright (c) 2009 - 2016, Intel Corporation. All rights reserved.<BR>
+  Copyright (c) 2009 - 2017, Intel Corporation. All rights 
+ reserved.<BR>
   This program and the accompanying materials
   are licensed and made available under the terms and conditions of the BSD License
   which accompanies this distribution.  The full text of the license may be found at @@ -321,8 +321,6 @@ ShellCommandRunCd (
             if (EFI_ERROR (Status)) {
               ShellPrintHiiEx (-1, -1, NULL, STRING_TOKEN(STR_GEN_DIR_NF), gShellLevel2HiiHandle, L"cd", Param1Copy);
               ShellStatus = SHELL_NOT_FOUND;
-            } else {
-              ShellPrintHiiEx (-1, -1, NULL, STRING_TOKEN(STR_CD_PRINT), gShellLevel2HiiHandle, ShellGetCurrentDir(Drive));
             }
           }
         }
--
2.9.0.windows.1



^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] ShellPkg/cd: Do not print the destination dir when CD exits
  2017-01-26  4:34 [PATCH] ShellPkg/cd: Do not print the destination dir when CD exits Ruiyu Ni
  2017-01-26 14:51 ` Shah, Tapan
@ 2017-01-26 16:59 ` Carsey, Jaben
  1 sibling, 0 replies; 3+ messages in thread
From: Carsey, Jaben @ 2017-01-26 16:59 UTC (permalink / raw)
  To: Ni, Ruiyu, edk2-devel@lists.01.org
  Cc: Chris J Phillips, Tapan Shah, Carsey, Jaben

Reviewed-by: Jaben Carsey <jaben.carsey@intel.com>

> -----Original Message-----
> From: Ni, Ruiyu
> Sent: Wednesday, January 25, 2017 8:34 PM
> To: edk2-devel@lists.01.org
> Cc: Carsey, Jaben <jaben.carsey@intel.com>; Chris J Phillips
> <chrisp@hpe.com>; Tapan Shah <tapandshah@hpe.com>
> Subject: [PATCH] ShellPkg/cd: Do not print the destination dir when CD exits
> Importance: High
> 
> Before the "cd fs0:dir" fix, CD only prints destination directory
> when the destination contains ":".
> However, the "cd fs0:dir" fix changed CD to always print destination
> directory.
> 
> This patch changes CD to never print destination directory.
> 
> Contributed-under: TianoCore Contribution Agreement 1.0
> Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
> Cc: Jaben Carsey <jaben.carsey@intel.com>
> Cc: Chris J Phillips <chrisp@hpe.com>
> Cc: Tapan Shah <tapandshah@hpe.com>
> ---
>  ShellPkg/Library/UefiShellLevel2CommandsLib/Cd.c | 4 +---
>  1 file changed, 1 insertion(+), 3 deletions(-)
> 
> diff --git a/ShellPkg/Library/UefiShellLevel2CommandsLib/Cd.c
> b/ShellPkg/Library/UefiShellLevel2CommandsLib/Cd.c
> index d459a7a..dd4a740 100644
> --- a/ShellPkg/Library/UefiShellLevel2CommandsLib/Cd.c
> +++ b/ShellPkg/Library/UefiShellLevel2CommandsLib/Cd.c
> @@ -3,7 +3,7 @@
> 
>    (C) Copyright 2016 Hewlett Packard Enterprise Development LP<BR>
>    (C) Copyright 2015 Hewlett-Packard Development Company, L.P.<BR>
> -  Copyright (c) 2009 - 2016, Intel Corporation. All rights reserved.<BR>
> +  Copyright (c) 2009 - 2017, Intel Corporation. All rights reserved.<BR>
>    This program and the accompanying materials
>    are licensed and made available under the terms and conditions of the BSD
> License
>    which accompanies this distribution.  The full text of the license may be
> found at
> @@ -321,8 +321,6 @@ ShellCommandRunCd (
>              if (EFI_ERROR (Status)) {
>                ShellPrintHiiEx (-1, -1, NULL, STRING_TOKEN(STR_GEN_DIR_NF),
> gShellLevel2HiiHandle, L"cd", Param1Copy);
>                ShellStatus = SHELL_NOT_FOUND;
> -            } else {
> -              ShellPrintHiiEx (-1, -1, NULL, STRING_TOKEN(STR_CD_PRINT),
> gShellLevel2HiiHandle, ShellGetCurrentDir(Drive));
>              }
>            }
>          }
> --
> 2.9.0.windows.1



^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2017-01-26 16:59 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-01-26  4:34 [PATCH] ShellPkg/cd: Do not print the destination dir when CD exits Ruiyu Ni
2017-01-26 14:51 ` Shah, Tapan
2017-01-26 16:59 ` Carsey, Jaben

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox