Re: [PATCH v2 08/20] libmultipath: use const char* in open_file()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Mar 19, 2018 at 04:01:43PM +0100, Martin Wilck wrote:

Reviewed-by: Benjamin Marzinski <bmarzins@xxxxxxxxxx>
> Signed-off-by: Martin Wilck <mwilck@xxxxxxxx>
> ---
>  libmultipath/file.c | 6 +++---
>  libmultipath/file.h | 2 +-
>  2 files changed, 4 insertions(+), 4 deletions(-)
> 
> diff --git a/libmultipath/file.c b/libmultipath/file.c
> index e4951c92eb67..d5165ec6709a 100644
> --- a/libmultipath/file.c
> +++ b/libmultipath/file.c
> @@ -37,7 +37,7 @@
>   */
>  
>  static int
> -ensure_directories_exist(char *str, mode_t dir_mode)
> +ensure_directories_exist(const char *str, mode_t dir_mode)
>  {
>  	char *pathname;
>  	char *end;
> @@ -80,7 +80,7 @@ sigalrm(int sig)
>  }
>  
>  static int
> -lock_file(int fd, char *file_name)
> +lock_file(int fd, const char *file_name)
>  {
>  	struct sigaction act, oldact;
>  	sigset_t set, oldset;
> @@ -118,7 +118,7 @@ lock_file(int fd, char *file_name)
>  }
>  
>  int
> -open_file(char *file, int *can_write, char *header)
> +open_file(const char *file, int *can_write, const char *header)
>  {
>  	int fd;
>  	struct stat s;
> diff --git a/libmultipath/file.h b/libmultipath/file.h
> index 4f96dbf55e34..70bffa5301ad 100644
> --- a/libmultipath/file.h
> +++ b/libmultipath/file.h
> @@ -6,6 +6,6 @@
>  #define _FILE_H
>  
>  #define FILE_TIMEOUT 30
> -int open_file(char *file, int *can_write, char *header);
> +int open_file(const char *file, int *can_write, const char *header);
>  
>  #endif /* _FILE_H */
> -- 
> 2.16.1

--
dm-devel mailing list
dm-devel@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/dm-devel



[Index of Archives]     [DM Crypt]     [Fedora Desktop]     [ATA RAID]     [Fedora Marketing]     [Fedora Packaging]     [Fedora SELinux]     [Yosemite Discussion]     [KDE Users]     [Fedora Docs]

  Powered by Linux