MCPcopy Create free account
hub / github.com/Meituan-Dianping/SQLAdvisor / my_delete

Function my_delete

mysys/my_delete.c:20–40  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

18#include <my_sys.h>
19
20int my_delete(const char *name, myf MyFlags)
21{
22 int err;
23 DBUG_ENTER("my_delete");
24 DBUG_PRINT("my",("name %s MyFlags %d", name, MyFlags));
25
26 if ((err = unlink(name)) == -1)
27 {
28 my_errno=errno;
29 if (MyFlags & (MY_FAE+MY_WME))
30 {
31 char errbuf[MYSYS_STRERROR_SIZE];
32 my_error(EE_DELETE, MYF(ME_BELL+ME_WAITTANG+(MyFlags & ME_NOINPUT)),
33 name, errno, my_strerror(errbuf, sizeof(errbuf), errno));
34 }
35 }
36 else if ((MyFlags & MY_SYNC_DIR) &&
37 my_sync_dir_by_file(name, MyFlags))
38 err= -1;
39 DBUG_RETURN(err);
40} /* my_delete */
41
42#if defined(__WIN__)
43/**

Callers 11

mainFunction · 0.85
cache_remove_open_tmpFunction · 0.85
close_cached_fileFunction · 0.85
my_createFunction · 0.85
create_temp_fileFunction · 0.85
my_copyFunction · 0.85
my_create_with_symlinkFunction · 0.85
my_delete_with_symlinkFunction · 0.85
my_rename_with_symlinkFunction · 0.85
convert_fileFunction · 0.85
inline_mysql_file_deleteFunction · 0.85

Calls 3

my_errorFunction · 0.85
my_strerrorFunction · 0.85
my_sync_dir_by_fileFunction · 0.85

Tested by

no test coverage detected