X-Git-Url: http://git.lttng.org./?a=blobdiff_plain;f=libcounter%2Fshm.c;h=d9bccafcf6d3eaeccfb7cb977d775a520f6e0155;hb=9f5ade14faf36df6429d9c6e1d0360854a5669d0;hp=a2e1f819574b1e151165f369e8cbb50b047339a4;hpb=ebabbf580131acd1fe246c4d31fc5c044d36a038;p=lttng-ust.git diff --git a/libcounter/shm.c b/libcounter/shm.c index a2e1f819..d9bccafc 100644 --- a/libcounter/shm.c +++ b/libcounter/shm.c @@ -1,21 +1,7 @@ /* - * libcounter/shm.c + * SPDX-License-Identifier: LGPL-2.1-only * * Copyright (C) 2005-2012 Mathieu Desnoyers - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; only - * version 2.1 of the License. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA */ #define _LGPL_SOURCE @@ -31,15 +17,18 @@ #include #include #include -#include #include #include #include + #ifdef HAVE_LIBNUMA #include #include #endif -#include + +#include + +#include #include #include "../libringbuffer/mmap.h" @@ -382,6 +371,6 @@ struct lttng_counter_shm_ref lttng_counter_zalloc_shm(struct lttng_counter_shm_o void lttng_counter_align_shm(struct lttng_counter_shm_object *obj, size_t align) { - size_t offset_len = offset_align(obj->allocated_len, align); + size_t offset_len = lttng_ust_offset_align(obj->allocated_len, align); obj->allocated_len += offset_len; }