Skip to content

Commit

Permalink
v1.3.2
Browse files Browse the repository at this point in the history
  • Loading branch information
CreaterOS committed Jul 25, 2020
1 parent 20de47f commit 193fe61
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
Binary file not shown.
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@
@interface PaintingliteBackUpManager()
@property (nonatomic,strong)PaintingliteExec *exec; //执行语句
@property (nonatomic,strong)NSString *saveFilePath; //保存文件路径
@property (nonatomic,strong)NSFileHandle *fileHandle;
@end

@implementation PaintingliteBackUpManager
Expand Down Expand Up @@ -140,7 +139,6 @@ - (Boolean)execTableRowValue:(sqlite3 *)ppDb tableName:(NSString *__nonnull)tabl
}

success = true;
[self.fileHandle closeFile];

dispatch_semaphore_signal(signal);
});
Expand Down Expand Up @@ -287,11 +285,12 @@ - (Boolean)appendContent:(NSString *__nonnull)sqlContent{
/* 说明有文件了 */
NSFileHandle *fileHandle = [NSFileHandle fileHandleForWritingAtPath:self.saveFilePath];
[fileHandle seekToEndOfFile];
self.fileHandle = fileHandle;


//sqlContent追加换行
[fileHandle writeData:[[sqlContent stringByAppendingString:@"\n"] dataUsingEncoding:NSUTF8StringEncoding]];

[fileHandle closeFile];

return true;
}

Expand Down

0 comments on commit 193fe61

Please sign in to comment.