LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 11-05-2013, 11:24 PM   #1
aditya9
LQ Newbie
 
Registered: Nov 2013
Posts: 2

Rep: Reputation: Disabled
directory backup program in C


Hi, i'm trying to make a directory backup program in C without using any system call.I'm able to read the "SOURCE" directory contents(it's subfolders and different types of files) but don't know to create the same directory in "DESTINATION". If anybody can kindly reply. It's an urgent task for me and i'm stuck midway.
 
Old 11-06-2013, 01:21 AM   #2
pan64
LQ Addict
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 21,804

Rep: Reputation: 7306Reputation: 7306Reputation: 7306Reputation: 7306Reputation: 7306Reputation: 7306Reputation: 7306Reputation: 7306Reputation: 7306Reputation: 7306Reputation: 7306
would be nice to explain how do you want to implement anything without system calls. (does it mean to avoid the system() call itself or any call to the system).
Actually mkdir should work, it will create the destination dir, but it is a system call too....


What have you implemented?
 
Old 11-08-2013, 10:27 PM   #3
aditya9
LQ Newbie
 
Registered: Nov 2013
Posts: 2

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by pan64 View Post
would be nice to explain how do you want to implement anything without system calls. (does it mean to avoid the system() call itself or any call to the system).
Actually mkdir should work, it will create the destination dir, but it is a system call too....


What have you implemented?

Exactly...i've to avoid system() . Any other function is allowed like mkdir() , chdir() etc. First i've to recursively read a directory and it's contents and then copy the same in destination directory in the same format as of source directory.
 
Old 11-09-2013, 01:52 AM   #4
pan64
LQ Addict
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 21,804

Rep: Reputation: 7306Reputation: 7306Reputation: 7306Reputation: 7306Reputation: 7306Reputation: 7306Reputation: 7306Reputation: 7306Reputation: 7306Reputation: 7306Reputation: 7306
here you can find some tips (for example): http://stackoverflow.com/questions/2...n-unix-using-c
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
tar backup of an XP directory fof3 Linux - Newbie 2 03-31-2007 03:39 PM
Backup program keep thort Linux - Newbie 2 07-08-2006 06:28 AM
Backup of directory sanjibgupta Linux - Networking 2 09-05-2005 12:32 AM
Backup program? muah Linux - Software 2 08-28-2003 10:27 AM
Backup - what program is best? pix Linux - Newbie 2 07-15-2003 09:06 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 11:35 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration