text stringlengths 3.08k 10.5k |
|---|
#include <stdio.h>
#include <stdlib.h>
#include <time.h>
#define N 100
struct arquivo{
FILE *f;
int pos, MAX, *buffer;
};
void salvaArquivo(char *nome, int *V, int tam, int mudaLinhaFinal);
int comparar(const void *a, const void *b);
int criarAquivosOrdenados(char *nome);
void preencheBuffer(st... |
/*
* Copyright (c) 2010, <NAME>. 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 ... |
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <unistd.h>
#include <fcntl.h>
#include <inttypes.h>
#include <netinet/in.h>
#include <limits.h>
#include <getopt.h>
#include <regex.h>
#include <errno.h>
#include <openssl/evp.h>
#include <xar/xar.h>
off_t ... |
/*
+---------------------------------------------------------------------+
Copyright 2009, <NAME> and <NAME>
This file is part of Codeword.
Codeword is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as publis... |
#include <reboot.h>
#include <mini_uart.h>
#include <mailbox.h>
#include <cpio.h>
#include <allocator.h>
#include <string.h>
#include <allocator.h>
#include <fdt.h>
#include <timer.h>
#include <printf.h>
uint64_t initramfs_loc;
static char buf[0x200];
void cmd_help(void)
{
uart_send_string("help :print... |
#include <sys/ptrace.h>
#include <bits/types.h>
#include <sys/reg.h>
#include <sys/user.h>
#include <sys/wait.h>
#include <sys/types.h>
#include <unistd.h>
#include <stdlib.h>
#include <stdio.h>
#include <errno.h>
#include <assert.h>
#include <string.h>
#include <ctype.h>
#define FILE_TRACERS 1
#include "config.h"
#in... |
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you ... |
/* *INDENT-OFF* */
/*INDENT OFF*/
/* Description: sorted_array - insert and search in a sorted array of items
*/
/******************************************************************************
* This software is covered by the zlib/libpng license.
* The zlib/libpng license is a recognized open source license by
* the O... |
/*
* $Id$
*/
/*
* isotpsend.c
*
* Copyright (c) 2008 Volkswagen Group Electronic Research
* 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 re... |
/* Copyright © Triad National Security, LLC, and others. */
#define _GNU_SOURCE
#include <libgen.h>
#include <stdarg.h>
#include <stdbool.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <sys/mount.h>
#include <sys/stat.h>
#include <sys/statvfs.h>
#include <unistd.h>
#include "config.h"
#include... |
// SPDX-License-Identifier: GPL-2.0
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <assert.h>
#include <errno.h>
#include <fcntl.h>
#include <poll.h>
#include <unistd.h>
#include <linux/perf_event.h>
#include <sys/mman.h>
#include "trace_helpers.h"
#define DEBUGFS "/sys/kernel/debug/tracing/"
#de... |
#include <sys/types.h>
#include <sys/stat.h>
#include <fcntl.h>
#include <unistd.h>
#include <stdio.h>
#include <windows.h>
#include <winnt.h>
typedef int (*fixup_t)(unsigned char* ptr);
extern struct patch *patches;
struct patch {
DWORD addrVA;
char *buf;
DWORD size;
fixup_t fixup;
char desc[0... |
/*-
* Copyright (c) 2017--2018 <NAME>. 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 conditio... |
// Metablobs effect implemented with help from the following references:
// - https://seancode.com/demofx/
#define SCG_IMPLEMENTATION
#include "../scg.h"
#define NUM_BLOBS 3
#define METABLOBS_CONST_A 300.0f
#define METABLOBS_CONST_B 1024.0f
typedef struct lissajous_t {
float32_t scale_x;
float32_t scale_y;
... |
#pragma config PLLDIV = 1 // PLL Prescaler Selection bits (No prescale (4 MHz oscillator input drives PLL directly))
#pragma config CPUDIV = OSC1_PLL2// System Clock Postscaler Selection bits ([Primary Oscillator Src: /1][96 MHz PLL Src: /2])
#pragma config FOSC = XTPLL_XT // Oscillator Selection bits (XT oscill... |
/***************************************************************************//**
* @file
* @brief Code for PS board Si7212-EB demo
*******************************************************************************
* # License
* <b>Copyright 2018 Silicon Laboratories Inc. www.silabs.com</b>
**************************... |
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
#include "go.h"
/*
* a function named init is a special case.
* it is called by the initialization before
* main is run. to make it unique within a
* packa... |
/* $NetBSD: if_sppp.h,v 1.17 2002/04/14 12:24:28 martin Exp $ */
/*-
* Copyright (c) 2002 The NetBSD Foundation, Inc.
* All rights reserved.
*
* This code is derived from software contributed to The NetBSD Foundation
* by <NAME> <<EMAIL>>.
*
* Redistribution and use in source and binary forms, with or without
... |
#include <stdio.h>
#include <stdlib.h>
#include <time.h>
#include <mpi.h>
#include <assert.h>
#include <math.h>
int getMid(int s, int e) { return s + (e -s)/2; }
int min(int a, int b) { return (a<=b)?a:b; }
int *create_rand_nums(int num_elements) {
int *rand_nums = (int *)malloc(sizeof(int) * num_elements);
in... |
/*
* util.c
*
* Created on: May 14, 2019
* Author: aviv
*/
#include "util.h"
char** createFilesFromArgs(int argc, char* argv[]) {
int i;
char** inputFiles = malloc(sizeof(char*) * (argc - 1));
for (i = 1; i < argc; i++) {
inputFiles[i - 1] = strdup((argv[i]));
}
return inputFiles;
}
/* Read matr... |
/**
# NAME
psv-velf - Generate a Vita ELF
# SYNOPSIS
psv-velf in.elf out.velf
# ENVIRONMENT VARIABLES
- DEBUG (any value): print more details on stderr
# NOTES
A better configuration system shall used
to specify module name,nid,version ...
# SEE ALSO
- velf(5)
*/
#include <limits.h>
#include <stdint.h>
#... |
/**
* \file ping.c
* \brief
*/
/*
* Copyright (c) 2017 ETH Zurich.
* All rights reserved.
*
* This file is distributed under the terms in the attached LICENSE file.
* If you do not find this file, copies can be found by writing to:
* ETH Zurich D-INFK, Universitaetsstrasse 6, CH-8092 Zurich. Attn: Systems Gr... |
/*
* A litte game that generates a maze and lets the player find his/her
* way out of the maze.
*
* Maze is displayed on the VGA screen.
* Keyboard controls are:
* UP : w, k
* DOWN : s, j
* LEFT : a, h
* RIGHT : d, l
*
* done by MJoergen in August 2020
*/
#include "conio.h" // Function to wr... |
/*************************************************************************
* *
* Module: SortSites *
* *
* Sort by position... |
/*
* Tests for record handling functions
*
* Copyright 2006 <NAME>
*
* 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; either
* version 2.1 of the License, or (at your option) any l... |
/*
Teem: Tools to process and visualize scientific data and images
Copyright (C) 2008, 2007, 2006, 2005 <NAME>
Copyright (C) 2004, 2003, 2002, 2001, 2000, 1999, 1998 University of Utah
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser Ge... |
#include "extern.h"
#include <err.h>
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
/*
* We need to track current column.
* We always can have a current column even if there is no windows.
* And current column gives the current window if we have one.
*/
static void move_pane(struct pane *, struct pa... |
#include <stddef.h>
#include <stdint.h>
#include <stdio.h>
#include <stdbool.h>
#include <memory.h>
#include <algo.h>
#include "kernel/pmem.h"
#include "kernel/paging.h"
// Number of contiguous blocks of RAM
size_t pmem_blocks_count = 0;
// Number of free 4K pages
size_t usable_pages = 0;
// Index of the free block cu... |
/*
*
* Copyright 2019 AT&T Intellectual Property
* Copyright 2019 Nokia
*
* 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
*
* Unle... |
/* Nifty Launcher (by 32bits.io)
* .
* /
*
* (
* ... |
/*
* Copyright (C) 2018 Microchip Technology Inc. All rights reserved.
* <NAME> <<EMAIL>>
*/
#include "m2d/m2d.h"
#include "m2d/utils.h"
#include "utils.h"
#include <assert.h>
#include <cairo.h>
#include <drm_fourcc.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <time.h>
static void parse_... |
// SPDX-License-Identifier: BSD-3-Clause
/*
* Copyright (C) 2020 <NAME> <<EMAIL>>
*
* MIPS CPS initialization for MediaTek MT7621
*/
#include <config.h>
#include <types.h>
#include <mmio.h>
#include <mipscmregs.h>
#include <addrspace.h>
#include <genfuncs.h>
static const struct cm_region {
uint32_t base;
uint32... |
#define FC_CACHEDIR "/var/cache/fontconfig"
#define FC_NO_MT /* we don't use fontconfig in multi-threaded programs */
#define FC_TEMPLATEDIR "/share/fontconfig/conf.avail"
#define FONTCONFIG_PATH "/etc/fonts"
/* #undef AC_APPLE_UNIVERSAL_BUILD */
#define ALIGNOF_DOUBLE 8
#define ALIGNOF_VOID_P 8
/* #undef ENABLE_LIBXM... |
/*
Copyright 2020 <NAME>.
All rights reserved.
Read the 'LICENSE' file.
*/
#include "int.h"
static void
select_inodes (select_tags, delete_tags, action, part)
sqlite3_stmt * select_tags;
sqlite3_stmt * delete_tags;
sqlite3_stmt * action;
struct part * part;
{
sqlite3_bind_text(select_tags, 1, part->part, part-... |
/* Copyright (C) 1998, 1999, 2000 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by <NAME> <<EMAIL>>, 1998.
The GNU C 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 S... |
#include "json_topology.h"
#include "util.h"
#include <json/json.h>
#include <string.h>
struct json_error_info {
enum json_error type;
size_t line;
size_t row;
char key[10];
};
static int
cmpfunc(const void * a, const void * b){
return ( *(uint64_t*) a - *(uint64_t*) b );
}
static void
json_set_... |
/*
Created by <NAME>
Copyright © <NAME> inc 2019.
All rights reserved!
*/
static int currentpc (lua_State *L, CallInfo *ci) {
if (!isLua(ci)) return -1; /* function is not a Lua function? */
if (ci == L->ci)
ci->savedpc = L->savedpc;
return pcRel(ci->savedpc, ci_func(ci)->l.p);
}
static int current... |
/*
* ccommon - a cache common library.
* Copyright (C) 2013 Twitter, Inc.
*
* 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 r... |
/* ----------------------------------------------------------------------------
* ATMEL Microcontroller Software Support
* ----------------------------------------------------------------------------
* Copyright (c) 2010, Atmel Corporation
* All rights reserved.
*
* Redistribution and use in sou... |
#include "_ecdsa.h"
#include <string.h>
#include <stdio.h>
void signZZ_p(Sig * sig, char * msg, mpz_t d, mpz_t k, const CurveZZ_p * curve) {
mpz_t e, kinv;
int orderBits, digestBits;
// R = k * G, r = R[x]
PointZZ_p R;
pointZZ_pMul(&R, curve->g, k, curve);
mpz_init_set(sig->r, R.x);
mpz_mod(s... |
/*****************************************************************************
* play_wavfiles.c
*
* Plays one of a set of WAV files to speaker using PortAudio
* Selection is via keyboard input using Ncurses
* Wav file access uses Sndfile
*
************************************************************************... |
#include <stdint.h>
#include "sd_cache.h"
#include <string.h>
#include "rb_tree.h"
/*
* SD cache:
* 512byte blocks
* rb tree retrieval
* Doubly linked list for LRU replacement
* Fixed cache size set at compile time
* Write through
*
* rb tree
* Key = SD sector address
* Value = poi... |
#include <stdlib.h>
#include <stdio.h>
#include <time.h>
#include <progbase/events2.h>
#include <progbase/console.h>
/* custom constant event type ids*/
enum {
KeyInputEventTypeId,
RandomNumberEventTypeId,
SpaceHitEventTypeId
};
static Event * KeyInputEvent_new(EventHandler * sender, char keyCode);
static char Ke... |
/*
* Copyright 2013 <NAME>, <NAME>
*
* 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 ag... |
/*
Copyright 2008-2012 <NAME>
Copyright 2008-2011 <NAME>
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... |
#include "scoreboard.h"
/**
* @file scoreboard.c
* @brief This file contains the implementation of the scoreboard
*/
/** @name Global variables */
///@{
int record_points[5] = {-1, -1, -1, -1, -1};
///@}
/** @name Static variables */
///@{
static char record_names[5][11] = {"", "", "", "", ""};
static int recor... |
/*
* cpustatus - program to read and process CPU status information
* Initially looks at contents of /proc/stat
* For CPU state
*/
#include <stdio.h>
#include <string.h>
#include <math.h>
#include <sys/stat.h>
#include <libgen.h>
#include "wspy.h"
#include "error.h"
FILE *cpufile = NULL;
v... |
/*
* The MIT License (MIT)
*
* Copyright (c) 2014-2018, <NAME>
*
* 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 limitation the rights to use,... |
/*
*
* Copyright 2017 gRPC 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 or agree... |
/*
* Copyright (c) 2003 <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 ... |
#include <stdio.h>
#include <stdlib.h>
#include <stdint.h>
#include <stdbool.h>
#include <getopt.h>
#define GLFW_INCLUDE_NONE
#include <GL/gl3w.h>
#include <GLFW/glfw3.h>
#define countof(x) (sizeof(x) / sizeof(0[x]))
#define M_PI 3.141592653589793
#define ATTRIB_POINT 0
static GLuint
compile_shader(GLenum type, con... |
/*
*
* Copyright 2015, Google 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:
*
* * Redistributions of source code must retain the above copyright
* notice, this list of condi... |
/* Copyright Digital Equipment Corporation & INRIA 1988 */
/* Last modified_on Wed Feb 14 16:20:34 GMT+1:00 1990 by herve */
/* modified_on 17-OCT-1989 20:23:23.17 by <NAME> SDE/Galway */
/* BntoBnn.h: allowing to use the new interfaces of KerN */
#ifndef VMS
#include <stdlib.h>
... |
/*
* File I/O extension to the State Threads Library.
*/
/*
* The contents of this file are subject to the Mozilla Public
* License Version 1.1 (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.mozilla.org/MPL/
*
* Software ... |
/*
* Copyright (c) 2019 - 2021, ETH Zurich, Computer Engineering Group (TEC)
* 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 copy... |
/***************************************************************************/
/**
* @file main.c
* @brief Example using different voltage scaling levels to show influence on
* current draw in the Profiler
*******************************************************************************
* # License
* <b>Copyright 20... |
#include "ruleExecSubmit.h"
#include "ruleExecDel.h"
#include "reServerLib.h"
#include "objMetaOpr.h"
#include "icatHighLevelRoutines.h"
int
rsRuleExecDel (rsComm_t *rsComm, ruleExecDelInp_t *ruleExecDelInp)
{
rodsServerHost_t *rodsServerHost;
int status;
if (ruleExecDelInp == NULL) {
rodsLog(LOG_N... |
#include "pogo.h"
#include "bitmap.h"
#include "window.h"
static Screen *currentScreen;
WidgetRenderFunc render_functions[8];
Color Black_Color = {0,0,0,0};
Color Blue_Color = {0,0,0xFF,0};
Color White_Color = {0xFF,0xFF,0xFF,0};
Color Gray_Color = {0x80,0x80,0x80,0};
Color Dark_Color = {0x18,0x18,0x18,0};... |
/*
* Audio Event Triangulation demo for the Veracruz MCU Client
*
* This example application contains an audio sample of a "clap", an
* audio event with an associated location and timestamp. It connects
* to the configured Veracruz server in order to contribute its audio
* recording to the confidential computatio... |
// Copyright (c) 2012, <NAME>
// 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 ... |
/*
* Copyright 2011 <NAME>. All rights reserved.
*
* (This license applies to bupsplit.c and bupsplit.h only.)
*
* 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 ... |
#include "ref_rpn_kernel.h"
static inline void bbox_tranform_inv_fp16(__fp16* m_box, float* local_anchors, struct rpn_param* param)
{
int feat_size = param->feat_height * param->feat_width;
int c_4 = param->feat_chan / 4;
for(int i = 0; i < c_4; ++i)
{
for(int j = 0; j < (2 * feat_size); ++j)
... |
/*
* R : A Computer Language for Statistical Data Analysis
* Copyright (C) 2011--2018 The R Core Team.
*
* 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 Lice... |
/*
* by <NAME>
*
* Copyright 2003-2012 -- See accompanying license
*
*/
#include <stdio.h>
#include <string.h>
#include <cat/raw.h>
#include <cat/stduse.h>
#include <cat/match.h>
#include <cat/mem.h>
struct rex_match_loc locs[16];
void tmatch(char *pat, char *str)
{
struct rex_pat rp;
struct raw r;
int rv, e... |
/*
*
* Copyright 2017 Samsung Electronics All Rights Reserved.
*
* 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 require... |
// calendar program - <NAME> - fall-winter, 2014
//
// design parameters:
// 1. code my own calendar program, after the style of the bsd calendar utility
// 2. slowly add functionality related to emacs org-mode
// 3. learn a lot about coding and program design in the process
//
#include <stdio.h>
#include <stdlib.h>
#... |
/*
* Copyright (c) 2017-2018 Cisco and/or its affiliates.
* All rights reserved.
*/
#include <malloc.h>
#include <stdlib.h>
#include <string.h>
#include <curl/curl.h>
#include "log.h"
/*
* Memory for callbacks
*/
struct MemoryStruct {
char *memory;
size_t size;
};
static size_t
WriteMemoryCallback(... |
/**
* Copyright (C) 2019-2020 Tristan
* For conditions of distribution and use, see copyright notice in the COPYING file.
*/
#include "header_list.h"
#include <stdlib.h>
#include <strings.h>
#include <stdio.h>
/**
* To be tactical, I did a quick header-count test:
*
* |-----------------------------------------... |
/*
* Executable Parser Implementation
*
* 2018, Operating Systems
*/
#include <stdio.h>
#include <elf.h>
#include <unistd.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <fcntl.h>
#include <stdlib.h>
#include "exec_parser.h"
#define BUFSIZE 1024
static void fix_auxv(uintptr_t base, char *envp[])
{
Elf... |
/*
* Copyright (C) 2017 - 2018 FIX94
*
* This software may be modified and distributed under the terms
* of the MIT license. See the LICENSE file for details.
*/
#include <stdio.h>
#include <stdbool.h>
#include <inttypes.h>
#include <string.h>
#include "../cpu.h"
#include "../ppu.h"
#include "../mapper.h"
#inclu... |
#include <stdlib.h>
#include <stdio.h>
#include <pthread.h>
#include <unistd.h>
#include <math.h> // must link with -lm
/*
A program with a pipeline of 3 threads that interact with each other as producers and consumers.
- Input thread is the first thread in the pipeline. It gets input from the user and puts it in a bu... |
/* Sarien - A Sierra AGI resource interpreter engine
* Copyright (C) 1999-2001 <NAME> and <NAME>
*
* $Id: lzw.c,v 1.6 2002/03/31 00:15:08 cmatsuoka Exp $
*
* 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 F... |
/*
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... |
#include <semaphore.h>
#include <errno.h>
#include <pthread.h>
#include <stdio.h>
#include <stdbool.h>
#include <stdlib.h>
#include <unistd.h>
#define NUM_MONKEYS 30
enum ball_color { RED, GREEN, BLUE, YELLOW, NONE };
typedef struct _training_monkey_t{
enum ball_color first_ball;
enum ball_color second_ball;
... |
/*
* MIT License
*
* Copyright (c) 2018 <NAME> <<EMAIL>>
*
* 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 limitation the rights
* to use, cop... |
/*
Copyright 2016 Vanderbilt University
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... |
/*
* draw_tickers.c
*
* Copyright 2021 chehw <<EMAIL>>
*
* The MIT License
*
* 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 limitation th... |
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include "optparse.h"
struct opt_str scriptstr;
int flags[7];
int opt_level;
int tab_level;
const char *divchoices[] = {"old", "warn", "warnall", "new", NULL};
#define MAXW 10
int nW, Wactions[MAXW];
char *Wtails[MAXW];
const char *Wchoices[] = {
"ignore... |
#include "lpc288x.h"
#include "sdram_lpc.h"
#include <stdio.h>
#include "type.h"
#include "target.h"
#define SDRAM_PERIOD 16.6 // 60MHz
#define P2C(Period) (((Period<SDRAM_PERIOD)?0:(u32)((float)Period/SDRAM_PERIOD))+1)
#define PLL_MUL 5
#define PLL_DIV 1
typedef enum _... |
#include <stdio.h>
#include <string.h>
#include "httppil.h"
#include "httpapi.h"
int MyUrlHandler(UrlHandlerParam* param);
int MyUrlHandlerInit(HttpParam* hp, int uninit);
//URL handler list
UrlHandler urlHandlerList[]={
{"cfg.htm",MyUrlHandler,MyUrlHandlerInit},
{NULL},
};
HttpParam httpParam;
st... |
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <sys/types.h>
#include <sys/socket.h>
#include <netinet/in.h>
#include <arpa/inet.h>
#include <unistd.h>
#include <errno.h>
#define BUFSIZE 1024
int dx;
//======================================
struct myjobs {
char commandd[... |
/** getline.c
*
* Implementations for POSIX `getdelim` and `getline` functions for non-POSIX
* systems.
*
* Copyright (C) 2020 <NAME> <<EMAIL>>
*
* The latest version of this file can be downloaded from:
* <https://github.com/jamesderlin/getline-compatible>
*
* This software is provided 'as-is', wit... |
#pragma once
#include "hardware.h"
Opcode_table_t *init_opcode_table();
void init_alu_func_table();
#define OPCODE_LENGTH 6
// special register indexes
#define v0_REG 2 // used for syscall identification
#define v1_REG 3
#define a0_REG 4 // argument regs
#define a1_REG 5
#define a2_REG 6
#define sp_REG 29 // stack... |
#include <stdlib.h>
#include <stdio.h>
#include <stdint.h>
#include <string.h>
#include <unistd.h>
#include <time.h>
#include <dirent.h>
#include <sys/stat.h>
#include <fcntl.h>
#include <errno.h>
#include <linux/input.h>
#include <dbus/dbus-glib.h>
#define MICROSECONDS_PER_SECOND 1000000
#define NANOSECONDS_P... |
/*
* Copyright (c) 2022 <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 ... |
/*
* GPIOITInput.c
*
* Created on: Aug 6, 2021
* Author: bruno
*
* A library for GPIO input pins that trigger an interrupt on the rising edge,
* the falling edge, or both.
*
* There are several GPIO ports (A, B, C, ...) and 16 GPIO pins per port (0 to
* 15)
* It seems that the EXTI (extended interrupt ... |
/* GStreamer
* Copyright (C) 2020 <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.
*
*... |
/*
* lux OS kernel
* copyright (c) 2018 by <NAME>
*/
#pragma once
#include <acpi.h>
// We'll use INT 0x30 as a base for hardware IRQs
// Because if we use the I/O APIC, the legacy PIC can still make spurious IRQs
// so we need to handle those, so we'll use base 0x20 for the PIC when we use
// the I/O APIC -- if ... |
/*
* Displays linux /proc/pid/stat in human-readable format
*
* Build: gcc -o procstat procstat.c
* Usage: procstat pid
* cat /proc/pid/stat | procstat
*
* Homepage: http://www.brokestream.com/procstat.html
* Version : 2009-03-05
*
* <NAME>, http://www.brokestream.com, <EMAIL>
*
* 2007-09-19 changed ... |
#include "leapio.h"
#include "log.h"
#include <process.h>
static LEAP_CONNECTION _connection = NULL;
static leap_connect_callback_t _conn_cb = NULL;
static leap_connect_callback_t _devconn_cb = NULL;
static leap_tracking_callback_t _track_cb = NULL;
static BOOL _running = FALSE;
static BOOL _connected = FALSE;
static ... |
#include "freertos/FreeRTOS.h"
#include "freertos/event_groups.h"
#include "freertos/queue.h"
#include "esp_log.h"
#include "esp_event_loop.h"
#include "nvs_flash.h"
#include "driver/uart.h"
#include "soc/uart_struct.h"
#include "packet_filter.h"
#include "freertos/queue.h"
#include <stdio.h>
#include <stdlib.h>
#incl... |
/*
* This file is part of the GROMACS molecular simulation package.
*
* Copyright (c) 1991-2000, University of Groningen, The Netherlands.
* Copyright (c) 2001-2004, The GROMACS development team,
* check out http://www.gromacs.org for more information.
* Copyright (c) 2012,2013, by the GROMACS development team, l... |
/*
* IREMH3001 Mapper - The peTI-NESulator Project
* iremh3001.c
*
* Created by <NAME>.
* Copyright (c) 2002-2019 986-Studio.
*
*/
#include "iremh3001.h"
uint16_t iremh3001_prom_slot[3];
uint16_t iremh3001_vrom_slot[8];
int iremh3001_InitMapper(NesCart *cart)
{
set_prom_bank_16k(0x8000, 0);
set_... |
/**
* (C) Copyright 2018 Intel Corporation.
*
* 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... |
/* Standard header file */
#include <assert.h>
#include <nfp.h>
#include <stdint.h>
#include <types.h>
/* Autogenerated header files */
#include <nfp6000/nfp_cls.h>
#include <nfp6000/nfp_ctm.h>
#include <nfp6000/nfp_event.h>
#include <nfp6000/nfp_mac.h>
#include <nfp6000/nfp_me.h>
#include <nfp6000/nfp_pcie.h>
#inclu... |
#include <pebble.h>
#include "text.h"
#include "clock.h"
#include "locales.h"
#include "configs.h"
#include "keys.h"
static signed int tz_hour;
static uint8_t tz_minute;
static char tz_name[TZ_LEN];
#if !defined PBL_PLATFORM_APLITE
static signed int tz_hour_b;
static uint8_t tz_minute_b;
static char tz_name_b[TZ_LEN];... |
/*
httperf -- a tool for measuring web server performance
Copyright (C) 2000 Hewlett-Packard Company
Contributed by <NAME> <<EMAIL>>
This file is part of httperf, a web server performance measurment
tool.
This program is free software; you can redistribute it and/or
modify it under the te... |
/* $Id$ */
/* Copyright (c) 2008-2016 <NAME> <<EMAIL>> */
/* This file is part of DeforaOS System libc */
/* 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 ... |
/* julian-timegm-test.c */
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <time.h>
#include "julian-timegm.h"
static void Test1 (time_t t);
static void Test2 (int y, int m, int d);
static void Test3 (int y, int m, int d, int H, int M, int S);
static void Test4 (int jday, int jsec);
int main (v... |
/*
** Matrix Projection,
** Ref: Lohmann, Loktyushin, Stelzer, Scheffler (2018) bioRXiv
**
** G.Lohmann, MPI-KYB, Nov 2018
*/
#include <viaio/Vlib.h>
#include <viaio/VImage.h>
#include <viaio/mu.h>
#include <viaio/option.h>
#include <gsl/gsl_matrix.h>
#include <gsl/gsl_vector.h>
#include <gsl/gsl_errno.h>
#includ... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.