From 7856bf3569cc448fe3b360c3fca836593a0c0c7d Mon Sep 17 00:00:00 2001
From: guowenxue <guowenxue@gmail.com>
Date: Mon, 06 Nov 2023 17:01:27 +0800
Subject: [PATCH] format c source code

---
 ch1_fileIO/syserr.c |    7 ++++---
 1 files changed, 4 insertions(+), 3 deletions(-)

diff --git a/ch1_fileIO/syserr.c b/ch1_fileIO/syserr.c
index 75a34ac..df8ed1f 100644
--- a/ch1_fileIO/syserr.c
+++ b/ch1_fileIO/syserr.c
@@ -1,6 +1,7 @@
 
 #include <stdio.h>
 #include <errno.h>
+#include <unistd.h>
 #include <string.h>
 #include <sys/types.h>
 #include <sys/stat.h>
@@ -10,12 +11,12 @@
 {
   char   *file_name = "/test.txt";
   int    fd=-1;
-  
+
   fd=open(file_name, O_RDONLY, 066);
   if( fd < 0 )
   {
-      perror("Open file failure");  
-      printf("Open file %s failure: %s\n", file_name, strerror(errno));  
+      perror("Open file failure");
+      printf("Open file %s failure: %s\n", file_name, strerror(errno));
       return 0;
   }
 

--
Gitblit v1.9.1