checksrc: code style: use 'char *name' style

This commit is contained in:
Daniel Stenberg 2016-11-23 07:53:24 +01:00
parent bc7e08471c
commit dbadaebfc4
68 changed files with 330 additions and 329 deletions

View file

@ -34,12 +34,12 @@ size_t writefunction(void *ptr, size_t size, size_t nmemb, void *stream)
return (nmemb*size);
}
static CURLcode sslctx_function(CURL * curl, void * sslctx, void * parm)
static CURLcode sslctx_function(CURL *curl, void *sslctx, void *parm)
{
X509_STORE * store;
X509 * cert=NULL;
BIO * bio;
char * mypem = /* www.cacert.org */
X509_STORE *store;
X509 *cert=NULL;
BIO *bio;
char *mypem = /* www.cacert.org */
"-----BEGIN CERTIFICATE-----\n"\
"MIIHPTCCBSWgAwIBAgIBADANBgkqhkiG9w0BAQQFADB5MRAwDgYDVQQKEwdSb290\n"\
"IENBMR4wHAYDVQQLExVodHRwOi8vd3d3LmNhY2VydC5vcmcxIjAgBgNVBAMTGUNB\n"\
@ -107,7 +107,7 @@ static CURLcode sslctx_function(CURL * curl, void * sslctx, void * parm)
int main(void)
{
CURL * ch;
CURL *ch;
CURLcode rv;
rv=curl_global_init(CURL_GLOBAL_ALL);

View file

@ -133,14 +133,14 @@ static const char *curlx_usage[]={
/* This is a context that we pass to all callbacks */
typedef struct sslctxparm_st {
unsigned char * p12file;
const char * pst;
PKCS12 * p12;
EVP_PKEY * pkey;
X509 * usercert;
unsigned char *p12file;
const char *pst;
PKCS12 *p12;
EVP_PKEY *pkey;
X509 *usercert;
STACK_OF(X509) * ca;
CURL * curl;
BIO * errorbio;
CURL *curl;
BIO *errorbio;
int accesstype;
int verbose;
@ -196,7 +196,7 @@ static int ssl_app_verify_callback(X509_STORE_CTX *ctx, void *arg)
BIO_printf(p->errorbio, "entering ssl_app_verify_callback\n");
if((ok= X509_verify_cert(ctx)) && ctx->cert) {
unsigned char * accessinfo;
unsigned char *accessinfo;
if(p->verbose > 1)
X509_print_ex(p->errorbio, ctx->cert, 0, 0);
@ -228,10 +228,10 @@ static int ssl_app_verify_callback(X509_STORE_CTX *ctx, void *arg)
- an application verification callback (the function above)
*/
static CURLcode sslctxfun(CURL * curl, void * sslctx, void * parm)
static CURLcode sslctxfun(CURL *curl, void *sslctx, void *parm)
{
sslctxparm * p = (sslctxparm *) parm;
SSL_CTX * ctx = (SSL_CTX *) sslctx;
sslctxparm *p = (sslctxparm *) parm;
SSL_CTX *ctx = (SSL_CTX *) sslctx;
if(!SSL_CTX_use_certificate(ctx, p->usercert)) {
BIO_printf(p->errorbio, "SSL_CTX_use_certificate problem\n");
@ -270,24 +270,24 @@ int main(int argc, char **argv)
BIO* in=NULL;
BIO* out=NULL;
char * outfile = NULL;
char * infile = NULL;
char *outfile = NULL;
char *infile = NULL;
int tabLength=100;
char *binaryptr;
char* mimetype;
char* mimetypeaccept=NULL;
char* contenttype;
const char** pp;
unsigned char* hostporturl = NULL;
BIO * p12bio;
char *mimetype;
char *mimetypeaccept=NULL;
char *contenttype;
const char **pp;
unsigned char *hostporturl = NULL;
BIO *p12bio;
char **args = argv + 1;
unsigned char * serverurl;
unsigned char *serverurl;
sslctxparm p;
char *response;
CURLcode res;
struct curl_slist * headers=NULL;
struct curl_slist *headers=NULL;
int badarg=0;
binaryptr = malloc(tabLength);

View file

@ -84,7 +84,7 @@ URL_FILE *url_fopen(const char *url, const char *operation);
int url_fclose(URL_FILE *file);
int url_feof(URL_FILE *file);
size_t url_fread(void *ptr, size_t size, size_t nmemb, URL_FILE *file);
char * url_fgets(char *ptr, size_t size, URL_FILE *file);
char *url_fgets(char *ptr, size_t size, URL_FILE *file);
void url_rewind(URL_FILE *file);
/* we use a global one for convenience */

View file

@ -36,8 +36,8 @@
/* The MinGW headers are missing a few Win32 function definitions,
you shouldn't need this if you use VC++ */
#if defined(__MINGW32__) && !defined(__MINGW64__)
int __cdecl _snscanf(const char * input, size_t length,
const char * format, ...);
int __cdecl _snscanf(const char *input, size_t length,
const char *format, ...);
#endif
@ -77,7 +77,7 @@ size_t readfunc(void *ptr, size_t size, size_t nmemb, void *stream)
}
int upload(CURL *curlhandle, const char * remotepath, const char * localpath,
int upload(CURL *curlhandle, const char *remotepath, const char *localpath,
long timeout, long tries)
{
FILE *f;

View file

@ -52,7 +52,7 @@ void handle_error(const char *file, int lineno, const char *msg)
/* This array will store all of the mutexes available to OpenSSL. */
static MUTEX_TYPE *mutex_buf= NULL;
static void locking_function(int mode, int n, const char * file, int line)
static void locking_function(int mode, int n, const char *file, int line)
{
if(mode & CRYPTO_LOCK)
MUTEX_LOCK(mutex_buf[n]);