text stringlengths 3.08k 10.5k |
|---|
/*
* Copyright 2018 Robotic Eyes GmbH
*
* 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 t... |
/*
AirWatch iOS Software Development Kit
Copyright © 2012 AirWatch. All rights reserved.
Unless required by applicable law, this Software Development Kit and sample code is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
KIND, either express or implied. AirWatch expressly disclaims any an... |
/**
* Shelldone plugin 'wildcards'
*
* vim:ts=4:sw=4:expandtab
*
* Copyright (c) 2011, Ziirish <<EMAIL>>
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
* 1. Redistributions of source co... |
/******************************************************************************
* Game manager
******************************************************************************
*
* Copyright (c) 2021, the respective contributors, as shown by the AUTHORS file.
* All rights reserved.
*
* Redistribution and use in so... |
// Copyright 2014 Technical Machine, Inc. See the COPYRIGHT
// file at the top-level directory of this distribution.
//
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
/... |
/*
* Simple - REALLY simple memory mapping demonstration.
*
* Copyright (C) 2001 <NAME> and <NAME>
* Copyright (C) 2001 O'Reilly & Associates
*
* The source code in this file can be freely used, adapted,
* and redistributed in source or binary form, so long as an
* acknowledgment appears in derived source files... |
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <math.h>
#include "calb.h"
#define EPS 1.E-16
/*-------------------------------------------------------------------------
*
* LU decomposition:
*
* A = L1 (L1^{-1} A0)
* = L1 A1 P1
* = L1 L2 (L2^{-1} A1) P1
* = L1 L2 A2 P2 P1
* ... |
#include <avr/io.h>
#include <avr/interrupt.h>
#include <util/delay.h>
int types = 4;
int maxangle=150;
int minangle = 30;
//Configure PORTB 5 pin for servo motor 1 operation
void servo1_pin_config (void)
{
DDRB = DDRB | 0x20; //making PORTB 5 pin output
PORTB = PORTB | 0x20; //setting PORTB 5 pin to logic 1
}
... |
/**
* Copyright (c) 2017 - 2020, Nordic Semiconductor ASA
*
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without modification,
* are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright no... |
/*
* client.c - Practice 3
*
* 2018 drugescu <<EMAIL>>
*
* This is free software; you can redistribute it and/or modify it
* under the terms of the MIT license. See LICENSE for details.
*
*/
#include "utils.h"
struct sockaddr_in addr;
struct sockaddr_in server_addr;
char buffer[ BUF_SIZE ] = { 0 };
int sock =... |
/*
* Copyright (c) 2019 <NAME>, LLC
*
* SPDX-License-Identifier: Apache-2.0
*/
/*
* The time_days_from_civil function is derived directly from public
* domain content written by <NAME> and available at:
* http://howardhinnant.github.io/date_algorithms.html#days_from_civil
*/
#include <zephyr/types.h>
#include... |
#ifdef _WIN32
#define _CRT_SECURE_NO_WARNINGS
#endif
#include <coldforce/coldforce_http2.h>
// my app object
typedef struct
{
co_app_t base_app;
// my app data
co_http2_client_t* client;
} my_app;
bool on_my_push_request(
my_app* self, co_http2_client_t* http2_client,
const co_http2_stream_t* pu... |
/* Copyright (c) 2003-2018, Xively All rights reserved.
*
* This is part of the Xively C Client library,
* it is licensed under the BSD 3-Clause license.
*/
#include "xi_config.h"
#include "xi_event_dispatcher_api.h"
#include "xi_connection_data.h"
#include "xi_helpers.h"
xi_connection_data_t* xi_alloc_connection... |
/**
* @file jaln_string_utils.c
*
* Various string utilities
*
* @section LICENSE
*
* Source code in 3rd-party is licensed and owned by their respective
* copyright holders.
*
* All other source code is copyright Tresys Technology and licensed as below.
*
* Copyright (c) 2012 Tresys Technology LLC, Columbia... |
/*
* Copyright (c) 2020, Renesas Electronics Corporation. All rights reserved.
*
* SPDX-License-Identifier: BSD-3-Clause
*/
/*! *****************************************************************************
@file TSIP_Core_Boot_API.c
@brief Boot API
@par History
@subsection sub_history ... |
/*
LAPACKE_dgesv Example
=====================
The program computes the solution to the system of linear
equations with a square matrix A and multiple
right-hand sides B, where A is the coefficient matrix
and b is the right-hand side matrix:
Description
===========
The routine solves for X... |
#include <lib9.h>
#include "dat.h"
#include "fns.h"
#include "mcp.h"
#include "../port/screen.h"
#include "ucbtouch.h"
extern int touch_read_delay;
/* this can be uncommented and used to update the default touchcal table
static void
printtouchcal()
{
TouchCal *tc = &touchcal;
int i,n;
print("TouchCal touchcal = {\... |
/* USER CODE BEGIN Header */
/**
******************************************************************************
* @file : main.c
* @brief : Main program body
******************************************************************************
* @attention
*
* <h2><center>© Copyright (c) ... |
#include <stdio.h>
#include "mcce.h"
int assign_rad(PROT prot)
{
int i, j, k;
float r;
FILE *debug_fp;
int err=0;
prot_atom_element(prot);
for (i=0; i<prot.n_res; i++) {
for (j=0; j<prot.res[i].n_conf; j++) {
for (k=0; k<prot.res[i].conf[j].n_atom; k++) {
... |
// Options: --no-argc --no-arrays --no-bitfields --checksum --concise --no-consts --no-float --no-inline-function --max-array-dim 3 --max-array-len-per-dim 10 --max-block-depth 5 --max-block-size 4 --max-expr-complexity 2 --max-funcs 1 --max-pointer-depth 2 --no-pointers --no-structs --no-unions --no-volatiles --no-b... |
#include <basic.h>
#include <draw.h>
#include <math.h>
static inline int _get_index(const struct image* img, const int cor[2]) {
const int x = cor[0];
const int y = img->height - 1 - cor[1];
return y * img->width + x;
}
static inline int _flat_image_get_index(const struct FlatImage* img, const int cor[2]... |
// Long weekend values
#define PREV_BTN 100
#define NEXT_BTN 200
#define RIGHT_BTN 300
#define WRONG_BTN 400
#define BURY_BTN 600
#define DEFAULT_USER_ID 1
#define DEFAULT_FREQUENCY_MULTIPLIER 1
#define DEFAULT_MAX_STUDYING 30
#define DEFAULT_DIFFICULTY 1
#define DEFAULT_REMINDER_DAYS 4
#define LWE_PLUGIN_UPDATE_PERI... |
#include <stdio.h>
#include <stdlib.h>
#include <stdbool.h>
//Declare your rectangle structure here!
typedef struct rectangle_t {
int x, y, width, height;
} rectangle;
rectangle canonicalize(rectangle r) {
//WRITE THIS FUNCTION
if (r.width >= 0 && r.height >=0) {
return r;
}
if (r.width < 0) {
r.wi... |
//# vim: ts=2 sw=2 et :
// This code does not maintain a family structure as it does not even bother to store status codes.
// All it does it listen for the appropriate signal when any child dies.
// It would make a very poor substitute for init outside a container.
#include <stdio.h>
#include <errno.h>
#include <sig... |
/* sdljoystick.c: routines for dealing with the SDL joystick
Copyright (c) 2003-2004 <NAME>, <NAME>, <NAME>
Copyright (c) 2015 UB880D
$Id: sdljoystick.c 804 2016-06-01 10:46:07Z fredm $
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public Lic... |
#include "md4.h"
#include "md4_utils.h"
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <unistd.h>
#ifdef WIN32
#include <Winsock2.h>
#endif
static const char admin_key[] = ";admin=true";
static const char secret[] = "it's a secret";
static const char basic_oauth[] = "comment1=cooking%20MCs;userd... |
/*
* Copyright (c) 1988 Regents of the University of California.
* All rights reserved.
*
* %sccs.include.redist.c%
*
* @(#)if_dmv.h 7.4 (Berkeley) 06/28/90
*/
/*
* DMV-11 Driver
*
* Qbus Sync DDCMP interface - DMV operated in full duplex, point to point mode
*
* Written by <NAME> of Mt Xinu
* starting fr... |
#include "shs.h"
static uint32_t endian = 0xaabcdeff;
// constants
static uint32_t K[] = {0x5a827999, 0x6ed9eba1, 0x8f1bbcdc, 0xca62c1d6};
static uint32_t initials[] = {0x67452301, 0xefcdab89, 0x98badcfe, 0x10325476,
0xc3d2e1f0};
#define BLOCK_SIZE 64 // 512 bit blocks
#define ROTL(x... |
#include <stdio.h>
#include <sys/mman.h>
#include <sys/types.h>
#include <fcntl.h>
#include <stdint.h>
#include <stdlib.h>
#include <string.h>
#include <math.h>
#define BRAM_ADDR 0x41200000
#define GPIO_RATE_FSADJ 0x42000000
#define GPIO_RESET 0x40000000
int waveform_ramp (int *wave_array, int length, int ... |
/**
* Predmet: IFJ / IAL
* Projekt: Implementace interpretu imperativniho jazyka IFJ12
* Varianta: a/1/I
* Soubor: kmp.c
* Popis: Hledani podretezce v retezci pomoci Knuth-Moris-Prattova algoritmu
* Datum: 17.11.2012
* Autori: <NAME> <<EMAIL>>
* <NAME> <<EMAIL>>
* ... |
/* $NetBSD: h_execthr.c,v 1.3 2014/08/13 00:03:00 pooka Exp $ */
/*
* Copyright (c) 2011 The NetBSD Foundation, Inc.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
* 1. Redistributions ... |
#include "stm32f4xx.h"
#include "stm32f4xx_hal.h"
#include "stm32f4xx_hal_gpio.h"
#include "stm32f4xx_hal_rcc.h"
#include "cymric.h"
#include "cymric_semaphore.h"
#include "cymric_mutex.h"
// Initialize the GPIO pin corresponding to LED2 on the nucleo board
static void prv_led_gpio_init(void) {
GPIO_InitTypeDef s_in... |
/* function declarations */
static void tile(Monitor *);
static void monocle(Monitor *m);
static void bstack(Monitor *m);
static void deck(Monitor *m);
void
tile(Monitor *m)
{
unsigned int i, n, h, mw, my, ty, ns;
float mfacts = 0, sfacts = 0;
Client *c;
for (n = 0, c = nexttiled(m->clients); c; c = nexttiled(c->... |
/*
ip_cksum_packet.c
Author: <NAME> <<EMAIL>>
Copyright:
Copyright (c) 2002, 2003 SFNT Finland Oy.
All rights reserved
IP header checksum computation for an IPSEC engine packet.
*/
#include "sshincludes.h"
#include "interceptor.h"
#include "ip_cksum.h"
#define SSH_DEBUG_MODULE "SshIpCks... |
#include <stdio.h>
#include <stdbool.h>
#include <stdlib.h>
#include <string.h>
#include <inttypes.h>
#include <signal.h>
#include <unistd.h>
/*
* TODO:
* 1. overlapping structs
* 2. trigger UAF
* 3. exploit UAF
*
* example
* overwrite function pointer with system()
* argument to original functions must have u... |
#include "ops.h"
#include "common.h"
#include "jit.h"
#include "lightning.h"
// GNU Lightning's macros expect `_jit` to be a jit_state_t pointer
#define _jit (*(jit_state_t**)(&s->jj))
void jit_init(struct jit_state **pstate)
{
init_jit(NULL);
*pstate = calloc(1, sizeof **pstate);
}
void jit_fini(struct jit... |
#include <ir/ir.h>
#include <target/util.h>
static void init_state_xl(Data* data) {
emit_line("(defpackage :elvm-compiled (:use :lisp))");
emit_line("(in-package :elvm-compiled)");
emit_line("(export '(main))");
for (int i = 0; i < 7; i++) {
emit_line("(defvar %s 0)", reg_names[i]);
}
emit_line("(defva... |
/******************************************************************************
@{
@file PH.c
@brief pH measurement of water quality.
@par Revision History:
@version V0.2
@author ADI
@date Feb 2020
@par Revision History:
- V0.2, Feb 27th 2020: initial version.
Description:
-- For PH measurement... |
/**
* demo_jpeg.c
*
* This demo application dumps on the disk all the jpeg images carried by HTTP packets
* captured from a .pcap file or from the network.
* Each dump file is named: "dump_test/[srcIP]:[srcPort]_to_[dstIP]:[dstPort]_at_[timestamp].jpeg
*
* Created on: 19/09/2012
* ==============================... |
/*
* CDDL HEADER START
*
* The contents of this file are subject to the terms of the
* Common Development and Distribution License (the "License").
* You may not use this file except in compliance with the License.
*
* You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
* or http://www.opensolar... |
#include <stdio.h>
#include <string.h>
#include <stddef.h>
#include <fcntl.h>
#include <unistd.h>
#include <netinet/in.h>
#include <sys/sendfile.h>
#include <stdlib.h>
#include <limits.h>
#include <ev.h>
#define PORT 8080
#define BUFLEN 512
#define DOCROOT "/var/www"
enum method {UNKNOWN, GET, PUT};
unsigned long g_n... |
#include"support.h"
// Variabili globali di supporto
extern volatile sig_atomic_t stop;
extern volatile sig_atomic_t print;
extern pthread_mutex_t* lock;
extern msg_list **list;
// La dimensione di un intero in stringa
int dim_int_in_char(uint32_t value)
{
int count = 0;
while (value != 0)
{
value /... |
/*
* (C) Copyright 2011
* <NAME>, <<EMAIL>>
*
* See file CREDITS for list of people who contributed to this
* project.
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License as
* published by the Free Software Foundation; either version 2... |
/*
* Copyright (c) 2020-21, Kalopa Robotics Limited. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this l... |
#include <stdint.h>
typedef double fe12[12];
static inline double unset_bit59(const double x)
{
union {
double f64;
uint64_t u64;
} tmp = { .f64 = x };
tmp.u64 &= 0xF7FFFFFFFFFFFFFF;
return tmp.f64;
}
void fe12_mul_2_ref(fe12 C, const fe12 A, const fe12 B)
{
double l0, l1, l2, l3,... |
#ifndef __STDC_FORMAT_MACROS
#define __STDC_FORMAT_MACROS
#endif
#include <stdio.h>
#include <stdlib.h>
#include <getopt.h>
#include <string.h>
#include <inttypes.h>
#include "sci_to_int64.h"
#include "ttd_g3_cli.h"
static const struct option ttd_g3_longopts[] = {
{"version", no_argument, NULL, 'V'... |
/*
* Student Name: <NAME>
* Student NetID: jeb446
* Compiler Used: gcc
* Program Description:
* exercise 4 - this program handles multiple signals from the child
*/
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
#include <fcntl.h>
#include <signal.h>
#include <t... |
#include "./discord.h"
#include "./log.h"
#include "./json.h"
#include "./thirdparty/cws.h"
const char *discord_opcode_as_cstr(Discord_Opcode opcode)
{
switch (opcode) {
case DISCORD_OPCODE_DISPATCH:
return "DISCORD_OPCODE_DISPATCH";
case DISCORD_OPCODE_HEARTBEAT:
return "DISCORD_OPCODE_HEA... |
#include <stdio.h>
#include <math.h>
#include "./qlrender.h"
#define QL_STRINGIZE(x) #x
#define QL_CUSTOM_NAME(x) QL_STRINGIZE(x)
#ifdef QL_CUSTOM_STEP
#include QL_CUSTOM_NAME(QL_CUSTOM_STEP)
#endif
#ifdef QL_CUSTOM_RAYS
#include QL_CUSTOM_NAME(QL_CUSTOM_RAYS)
#endif
/*
Copyright (c) 2020 <NAME>.
Permission is hereby... |
/* $NetBSD: oosiop_gsc.c,v 1.3 2003/11/20 03:58:47 chs Exp $ */
/*
* Copyright (c) 2001 <NAME>. All rights reserved.
* Copyright (c) 2001,2002 <NAME>. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
... |
#include <stdio.h>
#include <stdlib.h>
int bissexto (int ano) { // Função para determinar se o ano é ou não bissexto
// Retorna 0 em ano normal e 1 em ano bissexto
return (ano % 4 == 0) && ((ano % 100 != 0) || (ano % 400 == 0));
}
int main()
{
// Struct para as datas
struct dma {
int dia;
... |
#ifndef HOOK_H
#define HOOK_H
// FIXME: This crashes randomly for different reasons
// bool
// Hook64(void *toHook, void *ourFunc, uint32_t length);
void
TrampolineHook64(void *target, void *ourFunc, int targetLength);
// TODO: x86 hooks are untested!
// bool
// Hook86(void *toHook, void *ourFunc, uint32_t length)... |
#include<stdio.h>
#include<string.h>
#include<stdlib.h>
#include<sys/socket.h>
#include<arpa/inet.h>
#include<unistd.h>
#include<pthread.h>
#include<unistd.h>
#include<time.h>
int counter=0;
int client_num=0;
int cities[10][10];
int fuel[10][10];
int cost[10][10];
int numbers[9];
//h function gia na... |
/*-
* Copyright (C) 2012, 2017 <NAME> <<EMAIL>>
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
* 1. Redistributions of source code must retain the above copyright
* notice, this list... |
/* $NetBSD: powerpc_machdep.c,v 1.11 2002/03/18 04:50:32 briggs Exp $ */
/*
* Copyright (C) 1995, 1996 <NAME>.
* Copyright (C) 1995, 1996 TooLs GmbH.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
... |
/*
* minimal_sig_oqs.c
*
* Minimal example of a post-quantum signature method implemented in liboqs.
*
*/
#include <stdio.h>
#include <stdlib.h>
#include <oqs/oqs.h>
/* Cleaning up memory etc */
void cleanup(uint8_t *msg, size_t msg_len, uint8_t *sig, size_t sig_len,
uint8_t *pub, uint8_t *priv, OQS_... |
/*!
* \file
* \brief Thingstream Click example
*
* # Description
* This example reads and processes data from Thingstream clicks.
*
* The demo application is composed of two sections :
*
* ## Application Init
* Initializes driver and power module.
*
* ## Application Task
* Reads the rec... |
#include "quadrature_encoder.h"
#define SWAP_BUTTONS_AND_ENCODERS
//-------------------------------------------#DEFINE------------------------------------------
#define Codeur_RCC RCC_AHB1Periph_GPIOA
#ifndef SWAP_BUTTONS_AND_ENCODERS
#define Codeur1_A GPIO_Pin_0
#define Codeur1_A_SOURCE GPIO... |
#include <stdio.h>
#include <malloc.h>
//Agacimizdaki dugumlerin bilgilerini tutacak olan struct yapisi
//Yukseklik bilgisini de tuttugumuza dikkat edin.
struct node {
int key;
struct node *right;
struct node *left;
int height;
};
//Asagidaki fonksiyon dugumun yuksekligini return eden yardimci fonksiyondur.
int y... |
#include "p30F3013.h"
//_FOSC(CSW_FSCM_OFF & FRC);
#pragma config FOSFPR = FRC // Oscillator (Internal Fast RC (No change to Primary Osc Mode bits))
#pragma config FCKSMEN = CSW_FSCM_OFF // Clock Switching and Monitor (Sw Disabled, Mon Disabled)
/********************************************************... |
#define NULL ((void*)0)
typedef unsigned long size_t; // Customize by platform.
typedef long intptr_t; typedef unsigned long uintptr_t;
typedef long scalar_t__; // Either arithmetic or pointer type.
/* By default, we understand bool (as a convenience). */
typedef int bool;
#define false 0
#define true 1
/* Forward d... |
/* *
* Filters a fastq file based on the average quality of a substring
*/
#include <stdio.h>
#include <stdlib.h>
#include <bstrlib.h>
// * The [libbstring] (https://github.com/msteinert/bstring) shared object library needs
// to be in your LD\_LIBRARY\_PATH. This library can speed up your string manip... |
/******************************************************************************/
/* File: sdlog_test.c - Implementation for sdlog test appendage to sdcardtest4.
*
* This file contains the test code scraped out of sdcardtest4.c.
*/
#include <math.h>
#include <string.h>
#include "libmiscstm32/printf.h"
#include "sdcar... |
#include "token.h"
#include "io_stream.h"
#include "regex.h"
#include <string.h>
#include <assert.h>
#include <stdio.h>
struct token get_next_token(struct stream* input_stream) // This function was added later to not modify next_token for previous accepted regex
{
input_stream->prev_index = input_stream->cur_pos;
... |
/*
* CDDL HEADER START
*
* The contents of this file are subject to the terms of the
* Common Development and Distribution License, Version 1.0 only
* (the "License"). You may not use this file except in compliance
* with the License.
*
* You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
* o... |
/* GStreamer
* Copyright (C) 2009 <NAME> <<EMAIL>>
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Library General Public
* License as published by the Free Software Foundation; either
* version 2 of the License, or (at your option) any later version.
*
*... |
#include "csm_all.h"
#include <time.h>
#include "math_utils.h"
inline float myasin(float x) {
const float threshold = .52;
if(x > threshold) {
static float z, der0, der1,der2,der3;
static int first = 1;
if(first) {
z = 0.5* (threshold + 0.707);
der0 = asin(z);
float M = 1-z*z;
der1 = 1 / sqrt(M);... |
/*
* Copyright (C) 2012-2017 Red Hat, Inc.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program ... |
/*
* MikroSDK - MikroE Software Development Kit
* Copyright© 2020 MikroElektronika d.o.o.
*
* Permission is hereby granted, free of charge, to any person
* obtaining a copy of this software and associated documentation
* files (the "Software"), to deal in the Software without restriction,
* including without... |
/*
* Copyright (c) 1982, 1986, 1989, 1990, 1991, 1993
* The Regents of the University of California. All rights reserved.
* (c) UNIX System Laboratories, Inc.
* All or some portions of this file are derived from material licensed
* to the University of California by American Telephone and Telegraph
* Co. or Unix... |
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
#include <errno.h>
#include <pthread.h>
#include <sys/socket.h>
#include <arpa/inet.h>
#include <stdint.h>
#include "proto.h"
#include "user.h"
static int tcp_listen(char *ip, char *port);
#define MAX_THREADS 128
struct thread_pool {
p... |
/* mmix.h -- Header file for MMIX opcode table
Copyright (C) 2001, 2003 Free Software Foundation, Inc.
Written by <NAME> (<EMAIL>)
This file is part of GDB, GAS, and the GNU binutils.
GDB, GAS, and the GNU binutils are free software; you can redistribute
them and/or modify them under the terms of the GNU Genera... |
/*
* Copyright (c) 2004 <NAME> <<EMAIL>>
*
* This file is part of FFmpeg.
*
* FFmpeg 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; either
* version 2.1 of the License, or (at your option) any ... |
#include "gif.h"
#if defined (__ARM_ARCH_7A__)
extern void memset32_neon(uint32_t* dst, uint32_t value, int count);
#define MEMSET_ARGB(dst, value, count) memset32_neon(dst, value, (int) count)
#elif defined (__arm__)
extern void arm_memset32(uint32_t* dst, uint32_t value, int count);
#define MEMSET_ARGB(dst, value, c... |
/**
* @file platform.c
* @brief TODO.
*
*/
#include <string.h>
#include "stm32f7xx.h"
#include "stm32f7xx_hal.h"
#include "FreeRTOS.h"
#include "task.h"
#include "debug.h"
#include "led.h"
#include "platform.h"
#ifdef BUILD_TYPE_DEBUG
#include "uart1.h"
#endif
/**
* @brief Configure the MPU attributes as Devi... |
#include <stdint.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
#include <netdb.h>
#include <arpa/inet.h>
#include <netinet/in.h>
#include <sys/socket.h>
#include <sys/types.h>
#ifndef HOST
#define HOST "secure-asset-manager-4235c8a4.challenges.bsidessf.net"
#endif
#ifndef PORT
#de... |
/*
Copyright (c) 2015, Plume Design Inc. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
1. Redistributions of source code must retain the above copyright
notice, this list of conditions and the... |
/*
* Driver for RobotFuzz OSIF
*
* Copyright (c) 2013 <NAME> <<EMAIL>>
* Copyright (c) 2007 <NAME> <<EMAIL>>
*
* Based on the i2c-tiny-usb by
*
* Copyright (C) 2006 <NAME> (<EMAIL>)
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License... |
/*
* File : application.c
* This file is part of RT-Thread RTOS
* COPYRIGHT (C) 2006, RT-Thread Development Team
*
* The license and distribution terms for this file may be
* found in the file LICENSE in this distribution or at
* http://www.rt-thread.org/license/LICENSE
*
* Change Logs:
* Date ... |
// functions for demonstrating logging and string return values
#include "hello.h"
#include <string.h> // for strlen
#include <stdio.h> // for sprintf, which is not in string.h ...
#include <pthread.h> // for pthreads
#include <unistd.h> // int16_t and other standardiz... |
#include <stdio.h>
#include <stdlib.h>
#include <pthread.h>
typedef struct{
int l, r; //Limite a esquerda e limite a direita do vetor, respectivamente
} Partition;
int *vetor = NULL; //Esse é o nosso vetor que vai ser lido e depois ordenado
void *merge(void *arg){
Partition dados = *((Partition*) arg);
... |
/*-------------------------------------------------------------------------
*
* cdbappendonlyxlog.c
*
* Portions Copyright (c) 2009-2010, Greenplum inc
* Portions Copyright (c) 2012-Present Pivotal Software, Inc.
*
*
* IDENTIFICATION
* src/backend/cdb/cdbappendonlyxlog.c
*
*------------------------------... |
/*
* ndisc-linux.c
*
* Copyright (c) 2000 <NAME> <<EMAIL>>
*
*/
#include "config.h"
#include <sys/types.h>
#include <sys/ioctl.h>
#include <sys/socket.h>
#include <sys/uio.h>
#include <asm/types.h>
#include <netinet/in.h>
#include <linux/netlink.h>
#include <linux/rtnetlink.h>
#include <net/route.h>
#include ... |
// Copyright 2020 Google LLC. All rights reserved.
// SPDX-License-Identifier: BSD-2-Clause
#include "avif/internal.h"
#include "gav1/decoder.h"
#include <string.h>
struct avifCodecInternal
{
Libgav1DecoderSettings gav1Settings;
Libgav1Decoder * gav1Decoder;
const Libgav1DecoderBuffer * gav1Image;
a... |
#include "m_apm.h"
static M_APM M_div_a;
static M_APM M_div_b;
static M_APM M_div_c;
static M_APM M_div_r;
static int M_div_firsttime = TRUE;
/****************************************************************************/
void M_free_all_div()
{
if (M_div_firsttime) return;
M_div_firsttime = TRUE;
... |
/**
* @file op_model_athlon.h
* athlon / K7 model-specific MSR operations
*
* @remark Copyright 2002 OProfile authors
* @remark Read the file COPYING
*
* @author <NAME>
* @author <NAME>
* @author <NAME>
*/
#include <linux/oprofile.h>
#include <asm/ptrace.h>
#include <asm/msr.h>
#include <asm/nmi.h>
#includ... |
/* ntpshmmon.c -- monitor the inner end of an ntpshmwrite.connection
*
* This file is Copyright (c) 2010 by the GPSD project
* SPDX-License-Identifier: BSD-2-clause
*
*/
/* sys/ipc.h needs _XOPEN_SOURCE, 500 means X/Open 1995 */
#define _XOPEN_SOURCE 500
#include <stdio.h>
#include <string.h> /* for memset()... |
#include <filetypes.h>
#pragma pack(push, 1)
typedef struct {
char sign[3]; // "NES"
char id; // 0x1a
unsigned char nprg; // x16K PRG
unsigned char nchr; // x8K CHR
unsigned char flag6;
unsigned char flag7;
unsigned char flag8;
unsigned char flag9;
unsigned char flagA;
unsigned char res[5];
} xNesHead... |
/*
* Copyright 2011-2012 the Redfish authors
*
* 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 ... |
#define STRICT_R_HEADERS
#define R_NO_REMAP
#include "Rinternals.h"
#include <stdlib.h>
#include <string.h>
SEXP set(SEXP x, int i, SEXP val) {
R_xlen_t len = Rf_xlength(x);
if (i >= len) {
len *= 2;
x = Rf_lengthgets(x, len);
}
SET_VECTOR_ELT(x, i, val);
return x;
}
SEXP resize(SEXP out, R_xlen_t n... |
// Options: --no-argc --no-arrays --no-bitfields --checksum --concise --no-consts --no-float --no-inline-function --max-array-dim 3 --max-array-len-per-dim 10 --max-block-depth 5 --max-block-size 4 --max-expr-complexity 2 --max-funcs 1 --max-pointer-depth 2 --no-pointers --no-structs --no-unions --no-volatiles --no-b... |
/*
* Copyright (c) 2014 <NAME> <<EMAIL>>
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
* 1. Redistributions of source code must retain the above copyright
* notice, this list of con... |
// SPDX-License-Identifier: GPL-2.0+
/*
* (C) Copyright 2003 <NAME> <<EMAIL>>
*
* (C) Copyright 2000
* <NAME>, DENX Software Engineering, <EMAIL>.
*/
#include <common.h>
#include <asm/timer.h>
#include <asm/immap.h>
#include <watchdog.h>
DECLARE_GLOBAL_DATA_PTR;
static volatile ulong timestamp = 0;
#ifndef CO... |
const char rcsid_kd_types_c[] = "$Id: kd_types.c,v 1.7 2003/02/03 05:14:31 dmshaw Exp $";
/*
* Copyright (c) 1996, 1997, 1998, 1999, <NAME>. All rights reserved.
* See the LICENSE file in the release for redistribution information.
*/
#include <stdlib.h>
#include <sys/types.h>
#include <string.h>
#include "dat... |
/*
* SPDX-FileCopyrightText: 2021-2022 Espressif Systems (Shanghai) CO LTD
*
* SPDX-License-Identifier: Unlicense OR CC0-1.0
*/
#include "freertos/FreeRTOS.h"
#include "freertos/task.h"
#include "esp_check.h"
#include "esp_sleep.h"
#include "soc/uart_pins.h"
#include "driver/uart.h"
#include "driver/gpio.h"
#defin... |
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include "mvnc.h"
void *loadfile(const char *path, unsigned int *length)
{
FILE *fp;
char *buf;
fp = fopen(path, "rb");
if(fp == NULL)
return 0;
fseek(fp, 0, SEEK_END);
*length = ftell(fp);
rewind(fp);
if(!(buf = malloc(*length)))
{
fclose(fp);
... |
#include <stdio.h>
#include <stdlib.h>
#include <ctype.h>
#include <stdbool.h>
#define TOP_FLOOR 10
#define DELAY_FACTOR 1000
// Global Type Declarations
typedef enum {OUT, IN} BUTTON_STATUS;
typedef enum {DOWN, STOP, UP} DIRECTION_STATUS;
typedef struct
{
int currentFloor;
BUTTON_STATUS* buttons;
} ELEVATOR;
... |
// Particle System demo using instanced meshes for particles
// <NAME> <<EMAIL>> 9 July 2020
#include "apg/apg_gfx.h"
#include "apg/apg_ply.h"
#include "apg/apg_rand.h"
#include <stdio.h>
#define PARTICLES_MAX 128
const int n_particles = 128;
const double system_time = 1.5;
// instanced particle system propertie... |
/** \file
* \brief Frame Control.
*
* See Copyright Notice in "iup.h"
*/
#include <stdio.h>
#include <stdlib.h>
#include "iup.h"
#include "iupcbs.h"
#include "iup_object.h"
#include "iup_attrib.h"
#include "iup_str.h"
#include "iup_drv.h"
#include "iup_drvfont.h"
#include "iup_stdcontrols.h"
#include "iup_layout... |
///////////////////////////////////////////////////////////////////////////////
//
/// \file xzdec.c
/// \brief deCompress from stdin to stdout in multi-call mode
///
//
// Author: ting.guit
//
// This file has been put into the public domain.
// You can do whatever you want with this file.
//
///////... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.