From: Pawel Szewczyk Date: Tue, 26 Aug 2014 09:36:48 +0000 (+0200) Subject: gt: Add zalloc function X-Git-Tag: accepted/tizen/3.0/common/20161114.110810~115 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=2bec967b5b96aa9e081bffbd2654de8e34318440;p=platform%2Fupstream%2Fgt.git gt: Add zalloc function Change-Id: Ifd4de1238edf4ab95a65a5006e6761e7618e8bee Signed-off-by: Pawel Szewczyk --- diff --git a/source/base/include/common.h b/source/base/include/common.h new file mode 100644 index 0000000..6a3f01c --- /dev/null +++ b/source/base/include/common.h @@ -0,0 +1,27 @@ +/* + * Copyright (c) 2012-2013 Samsung Electronics Co., Ltd. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef __GADGET_TOOL_COMMON_H__ +#define __GADGET_TOOL_COMMON_H__ + +#include + +static inline void *zalloc(size_t size) +{ + return calloc(1, size); +} + +#endif //__GADGET_TOOL_COMMON_H__