X-Git-Url: http://git.efficios.com/?a=blobdiff_plain;f=types%2Finteger.c;h=58b6104f9f08c73e78a9730796afd155962ead7d;hb=fe2b0e243a39ba31130512a1678ad46720bab9f3;hp=212d8d489ce35f04562ff7e10ddfb26a09c95d31;hpb=1f7b01c261b8bd6c2640c0776f0a69865dff0ad8;p=babeltrace.git diff --git a/types/integer.c b/types/integer.c index 212d8d48..58b6104f 100644 --- a/types/integer.c +++ b/types/integer.c @@ -16,6 +16,14 @@ * * The above copyright notice and this permission notice shall be included in * all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + * SOFTWARE. */ #include @@ -77,7 +85,7 @@ struct definition * int ret; integer = g_new(struct definition_integer, 1); - declaration_ref(&integer_declaration->p); + bt_declaration_ref(&integer_declaration->p); integer->p.declaration = declaration; integer->declaration = integer_declaration; integer->p.ref = 1; @@ -103,11 +111,11 @@ void _integer_definition_free(struct definition *definition) struct definition_integer *integer = container_of(definition, struct definition_integer, p); - declaration_unref(integer->p.declaration); + bt_declaration_unref(integer->p.declaration); g_free(integer); } -enum ctf_string_encoding get_int_encoding(const struct definition *field) +enum ctf_string_encoding bt_get_int_encoding(const struct definition *field) { struct definition_integer *integer_definition; const struct declaration_integer *integer_declaration; @@ -118,7 +126,7 @@ enum ctf_string_encoding get_int_encoding(const struct definition *field) return integer_declaration->encoding; } -int get_int_base(const struct definition *field) +int bt_get_int_base(const struct definition *field) { struct definition_integer *integer_definition; const struct declaration_integer *integer_declaration; @@ -129,7 +137,7 @@ int get_int_base(const struct definition *field) return integer_declaration->base; } -size_t get_int_len(const struct definition *field) +size_t bt_get_int_len(const struct definition *field) { struct definition_integer *integer_definition; const struct declaration_integer *integer_declaration; @@ -140,7 +148,7 @@ size_t get_int_len(const struct definition *field) return integer_declaration->len; } -int get_int_byte_order(const struct definition *field) +int bt_get_int_byte_order(const struct definition *field) { struct definition_integer *integer_definition; const struct declaration_integer *integer_declaration; @@ -151,7 +159,7 @@ int get_int_byte_order(const struct definition *field) return integer_declaration->byte_order; } -int get_int_signedness(const struct definition *field) +int bt_get_int_signedness(const struct definition *field) { struct definition_integer *integer_definition; const struct declaration_integer *integer_declaration; @@ -162,7 +170,7 @@ int get_int_signedness(const struct definition *field) return integer_declaration->signedness; } -uint64_t get_unsigned_int(const struct definition *field) +uint64_t bt_get_unsigned_int(const struct definition *field) { struct definition_integer *integer_definition; const struct declaration_integer *integer_declaration; @@ -178,7 +186,7 @@ uint64_t get_unsigned_int(const struct definition *field) return (uint64_t)integer_definition->value._signed; } -int64_t get_signed_int(const struct definition *field) +int64_t bt_get_signed_int(const struct definition *field) { struct definition_integer *integer_definition; const struct declaration_integer *integer_declaration;