mirror of
https://github.com/samba-team/samba.git
synced 2025-01-12 09:18:10 +03:00
s3: Fix Coverity ID 2201, NULL_RETURNS
Autobuild-User: Volker Lendecke <vlendec@samba.org> Autobuild-Date: Wed Mar 23 13:06:20 CET 2011 on sn-devel-104
This commit is contained in:
parent
e88b9df78b
commit
cfa8b36632
@ -789,6 +789,9 @@ static WERROR winreg_printer_write_date(TALLOC_CTX *mem_ctx,
|
||||
} else {
|
||||
t = nt_time_to_unix(data);
|
||||
tm = localtime(&t);
|
||||
if (tm == NULL) {
|
||||
return map_werror_from_unix(errno);
|
||||
}
|
||||
str = talloc_asprintf(mem_ctx, "%02d/%02d/%04d",
|
||||
tm->tm_mon + 1, tm->tm_mday, tm->tm_year + 1900);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user