Some compiler error fixes.

git-svn-id: file:///home/bas/coolstream_public_svn/THIRDPARTY/applications/neutrino-experimental@591 e54a6e83-5905-42d5-8d5c-058d10e6a962
This commit is contained in:
nightshad
2010-05-20 09:32:01 +00:00
parent 8a11f636a7
commit a5a5cdc0e5
3 changed files with 7 additions and 7 deletions

View File

@@ -3982,7 +3982,7 @@ printf("\n");
find_new_part(npart, dpart); find_new_part(npart, dpart);
tt = time(0); tt = time(0);
printf("\n********* new file %s expected size %lld, start time %s", dpart, newsize, ctime (&tt)); printf("\n********* new file %s expected size %lld, start time %s", dpart, newsize, ctime (&tt));
dstfd = open (dpart, O_CREAT|O_WRONLY|O_TRUNC| O_LARGEFILE); dstfd = open (dpart, O_CREAT|O_WRONLY|O_TRUNC| O_LARGEFILE, 0644);
if(dstfd < 0) { if(dstfd < 0) {
perror(dpart); perror(dpart);
return 0; return 0;
@@ -4217,7 +4217,7 @@ printf("\ncopy: processing bookmark %d at %lld len %lld\n", i, books[i].pos, boo
} }
if(!dst_done || !onefile) { if(!dst_done || !onefile) {
find_new_part(npart, dpart); find_new_part(npart, dpart);
dstfd = open (dpart, O_CREAT|O_WRONLY|O_TRUNC| O_LARGEFILE); dstfd = open (dpart, O_CREAT|O_WRONLY|O_TRUNC| O_LARGEFILE, 0644);
printf("copy: new file %s fd %d\n", dpart, dstfd); printf("copy: new file %s fd %d\n", dpart, dstfd);
if(dstfd < 0) { if(dstfd < 0) {
printf("failed to open %s\n", dpart); printf("failed to open %s\n", dpart);

View File

@@ -1126,7 +1126,7 @@ void CMoviePlayerGui::PlayFile(void)
} else { } else {
char temp_name[255]; char temp_name[255];
char *slash = strrchr(filename, '/'); const char *slash = strrchr(filename, '/');
if (slash) { if (slash) {
slash++; slash++;
int len = strlen(slash); int len = strlen(slash);

View File

@@ -238,10 +238,10 @@ printf("[update] filename %s type %c newVersion %s md5 %s\n", filename.c_str(),
bool CFlashUpdate::getUpdateImage(const std::string & version) bool CFlashUpdate::getUpdateImage(const std::string & version)
{ {
CHTTPTool httpTool; CHTTPTool httpTool;
char * fname, dest_name[100]; char dest_name[100];
httpTool.setStatusViewer(this); httpTool.setStatusViewer(this);
fname = rindex(filename.c_str(), '/'); const char *fname = rindex(filename.c_str(), '/');
if(fname != NULL) fname++; if(fname != NULL) fname++;
else return false; else return false;
@@ -335,7 +335,7 @@ printf("[update] mode is %d\n", g_settings.softupdate_mode);
return false; return false;
} }
hide(); hide();
char * ptr = rindex(filename.c_str(), '.'); const char *ptr = rindex(filename.c_str(), '.');
if(ptr) { if(ptr) {
ptr++; ptr++;
if(!strcmp(ptr, "bin")) fileType = 'A'; if(!strcmp(ptr, "bin")) fileType = 'A';
@@ -381,7 +381,7 @@ int CFlashUpdate::exec(CMenuTarget* parent, const std::string &)
if(g_settings.softupdate_mode==1) //internet-update if(g_settings.softupdate_mode==1) //internet-update
{ {
char * fname = rindex(filename.c_str(), '/') +1; const char * fname = rindex(filename.c_str(), '/') +1;
char fullname[255]; char fullname[255];
if(!getUpdateImage(newVersion)) { if(!getUpdateImage(newVersion)) {