Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

curl_global_init_mem(3) [ultrix man page]

curl_global_init_mem(3) 					  libcurl Manual					   curl_global_init_mem(3)

NAME
curl_global_init_mem - Global libcurl initialisation with memory callbacks SYNOPSIS
#include <curl/curl.h> CURLcode curl_global_init_mem(long flags, curl_malloc_callback m, curl_free_callback f, curl_realloc_callback r, curl_strdup_callback s, curl_calloc_callback c ); DESCRIPTION
This function works exactly as curl_global_init(3) with one addition: it allows the application to set callbacks to replace the otherwise used internal memory functions. This man page only adds documentation for the callbacks, see the curl_global_init(3) man page for all the rest. When you use this function, all callback arguments must be set to valid function pointers. The prototypes for the given callbacks should match these: void *malloc_callback(size_t size); To replace malloc() void free_callback(void *ptr); To replace free() void *realloc_callback(void *ptr, size_t size); To replace realloc() char *strdup_callback(const char *str); To replace strdup() void *calloc_callback(size_t nmemb, size_t size); To replace calloc() CAUTION
Manipulating these gives considerable powers to the application to severly screw things up for libcurl. Take care! SEE ALSO
curl_global_init(3), curl_global_cleanup(3), libcurl 7.12.0 10 May 2004 curl_global_init_mem(3)

Check Out this Related Man Page

curl_global_init_mem(3) 					  libcurl Manual					   curl_global_init_mem(3)

NAME
curl_global_init_mem - Global libcurl initialisation with memory callbacks SYNOPSIS
#include <curl/curl.h> CURLcode curl_global_init_mem(long flags, curl_malloc_callback m, curl_free_callback f, curl_realloc_callback r, curl_strdup_callback s, curl_calloc_callback c ); DESCRIPTION
This function works exactly as curl_global_init(3) with one addition: it allows the application to set callbacks to replace the otherwise used internal memory functions. This man page only adds documentation for the callbacks, see the curl_global_init(3) man page for all the rest. When you use this function, all callback arguments must be set to valid function pointers. The prototypes for the given callbacks should match these: void *malloc_callback(size_t size); To replace malloc() void free_callback(void *ptr); To replace free() void *realloc_callback(void *ptr, size_t size); To replace realloc() char *strdup_callback(const char *str); To replace strdup() void *calloc_callback(size_t nmemb, size_t size); To replace calloc() CAUTION
Manipulating these gives considerable powers to the application to severly screw things up for libcurl. Take care! SEE ALSO
curl_global_init(3), curl_global_cleanup(3), libcurl 7.12.0 10 May 2004 curl_global_init_mem(3)
Man Page

15 More Discussions You Might Find Interesting

1. Programming

Complicating things?

So basically what im trying to do is ... Open file, read that file, than try to find .. We or we and replace them with I, but not replace the cases where words contain We or we, such as Went, went, etc a and replace them with the, but not replace the cases where words contain a, such as... (1 Reply)
Discussion started by: bconnor
1 Replies

2. Programming

how to find and replace string

hi I wanted to find this char " ^M " in my file and replace it with blank space. I am using Unix system. If i give command " :%s/^M//gc " it wont work so can anyone tell what is command to find and replace thankx (3 Replies)
Discussion started by: mridula
3 Replies

3. UNIX for Dummies Questions & Answers

vi command - replace

Hi, Given a long text file. How can I replace all full stops- with semicolon thanks, tictactoe (1 Reply)
Discussion started by: tictactoe
1 Replies

4. Shell Programming and Scripting

replace chars,

:rolleyes: Hi, I want to replace the particular text in the middle of the line. Ex. In the line 40-50 wanted to replace the char as 'x' (7 Replies)
Discussion started by: Jairaj
7 Replies

5. AIX

How to replace many numbers with one number in a file

How to replace many numbers with one number in a file. Many numbers like 444565,454678,443298,etc. i want to replace these with one number (300).Please halp me out. (2 Replies)
Discussion started by: vpandey
2 Replies

6. UNIX for Dummies Questions & Answers

How do you replace "|" with someting else?

I have a large file and I have to get rid of these pipes (|) that are everywhere... I have Googled around and found a way to find and replace text (sed -e 's/find/replace/g'). BUT, when I'm trying to replace "|" with "." nothing happens to the pipes but i get dots between every letter in he text...... (2 Replies)
Discussion started by: Draken
2 Replies

7. Shell Programming and Scripting

Replace spaces

Hi guys, so I have another issue. Can I use sed to replace spaces in a string or variable with %20 I am having trouble with using curl on URL's containing spaces Thanks! (12 Replies)
Discussion started by: tret
12 Replies

8. UNIX for Dummies Questions & Answers

sed - how to replace ' with \'

Hello, I have problem I can't solve. My task is to replace all apostrophes in my music library eg. I'm free to I/'m free I can select ' (apostrophe), but I can't find "to" section.. '/ echo "I'm free" | sed 's/'\''/what_shell_i_put_here/g' many thanks in advance, peter (3 Replies)
Discussion started by: piogac6088
3 Replies

9. UNIX for Dummies Questions & Answers

How to replace specific number in a file

Hi, i'm trying to find a way to replace some numbers in a file, but with no luck sofar. Let's say i have file with three columns, i would like to find specific line, and replace third column with different number. search_string="oa11 /home/testfile1.log" new_number=600 test file... (4 Replies)
Discussion started by: dusoo
4 Replies

10. Shell Programming and Scripting

How to conditionally replace a pattern?

Hi, How to replace only the function calls with a new name and skip the function definition and declarations. consider the following code. There are 2 functions defined here returnint and returnvoid. I need to replace returnint with giveint and returnvoid with givevoid only in the function... (2 Replies)
Discussion started by: i.srini89
2 Replies

11. UNIX for Dummies Questions & Answers

Replace and increment in xemacs 21.4

I am trying to replace and increment a lot of TEST_FONC_1 entries in my file with TEST_FONC_2 then TEST_FONC_3..... I'm trying to use replace regexp but it doesn't work I have tried replace _+ with _\,(1+ \#&) but it doesn't work. it find the entries but it replace it with the text... (4 Replies)
Discussion started by: Toug
4 Replies

12. UNIX for Dummies Questions & Answers

Global replace command help

Hello - I am trying to use a global replace command but its not working. Here is the cmd I am using in vi: :%s/OLD/NEW/g However, in my "NEW" I already have a "/" which is not making the replace work: :%s/mytestscript.com:33232/mytestscript:70245/test.com/g the... (2 Replies)
Discussion started by: DallasT
2 Replies

13. Shell Programming and Scripting

Remove Special Characters Within Text

Hi, I have a "|" delimited file that is exported from a database. There is one column in the file which has description/comments entered by some application user. It has "Control-M" character and "New Line" character in between the text. Hence, when i export the data, this record with the new... (4 Replies)
Discussion started by: tarun.trehan
4 Replies

14. Programming

Fscanf to get number and replace.

Hi, I have a file with contents like "abcd 1234" .What i need is get that integer and replace that with 0. So i used fscanf(fp,"%s %d", str, &num); This is having some problem. There can be multiple space/tab between string and number. How to replace that number with 0 in same file? (4 Replies)
Discussion started by: explore
4 Replies

15. UNIX for Beginners Questions & Answers

sed and replace

Hi All, I am trying to replace ", " with ",". For I am getting below error. I think I am missing something. I tried to escape the , with \ still I see the same error Input 110|3|401|0|CANDY, GUM, MINTS|GUM|SWENT||||| Output 110|3|401|0|CANDY,GUM,MINTS|GUM|SWENT||||| Command Tried... (3 Replies)
Discussion started by: arunkumar_mca
3 Replies