Click here to Skip to main content
15,881,516 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: A pointer reference as l-value Pin
Freak3021-Jan-13 22:08
Freak3021-Jan-13 22:08 
QuestionThe 'rename' function gives errno == -1 Pin
Anthony Appleyard20-Jan-13 1:12
Anthony Appleyard20-Jan-13 1:12 
AnswerRe: The 'rename' function gives errno == -1 Pin
pasztorpisti20-Jan-13 1:26
pasztorpisti20-Jan-13 1:26 
GeneralRe: The 'rename' function gives errno == -1 Pin
Anthony Appleyard20-Jan-13 3:01
Anthony Appleyard20-Jan-13 3:01 
AnswerRe: The 'rename' function gives errno == -1 Pin
Richard MacCutchan20-Jan-13 3:50
mveRichard MacCutchan20-Jan-13 3:50 
GeneralRe: The 'rename' function gives errno == -1 Pin
Anthony Appleyard20-Jan-13 4:32
Anthony Appleyard20-Jan-13 4:32 
GeneralRe: The 'rename' function gives errno == -1 Pin
Richard MacCutchan20-Jan-13 4:37
mveRichard MacCutchan20-Jan-13 4:37 
GeneralRe: The 'rename' function gives errno == -1 Pin
Anthony Appleyard20-Jan-13 5:02
Anthony Appleyard20-Jan-13 5:02 
The program text is

x=rename(orig,tempname); y=rename(cor,orig); z=rename(tempname,cor);

where x y z are integers and tempname cor tempname are big char arrays.

This is to swop the names of two files.

I run in the mode "Use Multi-Byte Character Set".

The string values are:-
orig = 'C:\Poser4\Runtime\Libraries\character\Divers\Divers_rebreathers\CDBA\cdba3_fr_hv_lm___2.cr2'
cor = 'C:\Poser4\Runtime\Libraries\character\Divers\Divers_rebreathers\CDBA\cdba3_fr_hv_lm___2_zz02.cr2'
tempname = 'C:\Poser4\Runtime\Libraries\character\Divers\Divers_rebreathers\CDBA\MIAOW_EE_EE_SAID_THE_CAT.txt'

The apostrophes are not in the strings.
The whimsical nature of tempname is to avoid coinciding with any permanent file.
I tested, and the temporary file does not exist already.
GeneralRe: The 'rename' function gives errno == -1 Pin
Richard MacCutchan20-Jan-13 5:04
mveRichard MacCutchan20-Jan-13 5:04 
GeneralRe: The 'rename' function gives errno == -1 Pin
Anthony Appleyard20-Jan-13 5:11
Anthony Appleyard20-Jan-13 5:11 
GeneralRe: The 'rename' function gives errno == -1 Pin
Richard MacCutchan20-Jan-13 5:33
mveRichard MacCutchan20-Jan-13 5:33 
GeneralRe: The 'rename' function gives errno == -1 Pin
Anthony Appleyard20-Jan-13 5:57
Anthony Appleyard20-Jan-13 5:57 
GeneralRe: The 'rename' function gives errno == -1 Pin
Richard MacCutchan20-Jan-13 6:20
mveRichard MacCutchan20-Jan-13 6:20 
GeneralRe: The 'rename' function gives errno == -1 Pin
Anthony Appleyard20-Jan-13 11:03
Anthony Appleyard20-Jan-13 11:03 
GeneralRe: The 'rename' function gives errno == -1 Pin
Richard MacCutchan20-Jan-13 21:52
mveRichard MacCutchan20-Jan-13 21:52 
GeneralRe: The 'rename' function gives errno == -1 Pin
Anthony Appleyard20-Jan-13 22:11
Anthony Appleyard20-Jan-13 22:11 
GeneralRe: The 'rename' function gives errno == -1 Pin
Richard MacCutchan20-Jan-13 23:00
mveRichard MacCutchan20-Jan-13 23:00 
QuestionRe: The 'rename' function gives errno == -1 Pin
David Crow20-Jan-13 15:17
David Crow20-Jan-13 15:17 
AnswerRe: The 'rename' function gives errno == -1 Pin
Anthony Appleyard20-Jan-13 18:15
Anthony Appleyard20-Jan-13 18:15 
GeneralRe: The 'rename' function gives errno == -1 Pin
Richard MacCutchan20-Jan-13 4:49
mveRichard MacCutchan20-Jan-13 4:49 
AnswerRe: The 'rename' function gives errno == -1 Pin
jschell20-Jan-13 6:13
jschell20-Jan-13 6:13 
GeneralBANZAI :: bug found Pin
Anthony Appleyard20-Jan-13 23:50
Anthony Appleyard20-Jan-13 23:50 
QuestionIs there a way to trace an mpi message through a topology? Pin
Cioroiu Adrian-Nicu19-Jan-13 6:39
Cioroiu Adrian-Nicu19-Jan-13 6:39 
AnswerRe: Is there a way to trace an mpi message through a topology? Pin
Richard MacCutchan19-Jan-13 21:32
mveRichard MacCutchan19-Jan-13 21:32 
QuestionSOLVED Cannot access #include files – “permission denied” Pin
Vaclav_19-Jan-13 4:38
Vaclav_19-Jan-13 4:38 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.