diff --git a/server/mailserver/mail/mail.go b/server/mailserver/mail/mail.go index 689d2fce..79b4ac2c 100644 --- a/server/mailserver/mail/mail.go +++ b/server/mailserver/mail/mail.go @@ -2,6 +2,7 @@ package mail import ( "f5" + "sync" //"main/common" //"main/constant" //"q5" @@ -14,6 +15,7 @@ type attachment struct { } type mail struct { + lock sync.Mutex mailId int64 mailType int32 subject string @@ -31,6 +33,14 @@ func (this *mail) init() { } +func (this *mail) Lock() { + this.lock.Lock() +} + +func (this *mail) Unlock() { + this.lock.Unlock() +} + func (this *mail) loadFromDb(ds *f5.DataSet) { }