aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--editors/patch.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/editors/patch.c b/editors/patch.c
index 3de293f03..33e744214 100644
--- a/editors/patch.c
+++ b/editors/patch.c
@@ -103,7 +103,7 @@ int patch_main(int argc, char **argv)
103 ret = 0; 103 ret = 0;
104 } 104 }
105 105
106 patch_line = xmalloc_fgets(patch_file); 106 patch_line = xmalloc_getline(patch_file);
107 while (patch_line) { 107 while (patch_line) {
108 FILE *src_stream; 108 FILE *src_stream;
109 FILE *dst_stream; 109 FILE *dst_stream;
@@ -122,7 +122,7 @@ int patch_main(int argc, char **argv)
122 */ 122 */
123 while (patch_line && strncmp(patch_line, "--- ", 4) != 0) { 123 while (patch_line && strncmp(patch_line, "--- ", 4) != 0) {
124 free(patch_line); 124 free(patch_line);
125 patch_line = xmalloc_fgets(patch_file); 125 patch_line = xmalloc_getline(patch_file);
126 } 126 }
127 /* FIXME: patch_line NULL check?? */ 127 /* FIXME: patch_line NULL check?? */
128 128
@@ -134,7 +134,7 @@ int patch_main(int argc, char **argv)
134#endif 134#endif
135 free(patch_line); 135 free(patch_line);
136 136
137 patch_line = xmalloc_fgets(patch_file); 137 patch_line = xmalloc_getline(patch_file);
138 /* FIXME: NULL check?? */ 138 /* FIXME: NULL check?? */
139 if (strncmp(patch_line, "+++ ", 4) != 0) { 139 if (strncmp(patch_line, "+++ ", 4) != 0) {
140 ret = 2; 140 ret = 2;