diff --git a/src/server/slavefuncs.c b/src/server/slavefuncs.c --- a/src/server/slavefuncs.c +++ b/src/server/slavefuncs.c @@ -65,12 +65,12 @@ int delete_jobdata(int jobnum, char *dat { char *jobpath; _distren_asprintf(&jobpath, "%s/%d", datadir, jobnum); - rmdir(jobpath); - fprintf(stderr, "I just failed to remove all of your job data because I can only delete empty directories! Haha!\nPlease contact the dev team :D\n\tWe'd be overjoyed to know that someone was willing to try to use this in this devel/design/planning stage ;-)\n"); + // rmdir(jobpath); + fprintf(stderr, "Please manually remove %s. Automatic removal is currently not implemented.\n", jobpath); return 0; } -/** Stub stub stubbiness ugh @TODO: Kill me. */ +/** Stub @TODO: Replace with remotio */ void tell_the_server(int stuff){ } @@ -109,7 +109,7 @@ int curlget(char *url, char *out){ curl_easy_cleanup(curl); } fprintf(stderr,"\n"); // Clears out he progressbar's carriage return - return res; // 0 means OK, nonzero means AAAH badness + return res; // 0 is OK, 1 is 404 or other error } /** Posts a file to a url with cUrl */ @@ -212,7 +212,6 @@ return 1; // Success /* Executors */ - /** Executor function for Blender operations */ void exec_blender(char *input, char *output, int frame) { @@ -220,9 +219,7 @@ void exec_blender(char *input, char *out int ret; char *frame_str; - /* start execio code */ - char *command = "blender"; // @TODO: append .exe if win32? - + char *command = "blender"; // @TODO: append .exe if win32? Do we expect this to be in the PATH? char *cmd[] = { command, "-b", "-o", output, input, "-f", frame_str, (char *)NULL }; char buf[10]; @@ -231,7 +228,7 @@ void exec_blender(char *input, char *out _distren_asprintf(&frame_str, "%i", frame); - ret = execio_open(&testrem, command, cmd); // This path will be absolute for testing, @TODO: should be relative to install on production + ret = execio_open(&testrem, command, cmd); buf[9] = '\0'; while(!execio_read(testrem, buf, 9, &readlen)) { @@ -240,22 +237,15 @@ void exec_blender(char *input, char *out } buf[readlen] = '\0'; fprintf(stderr, "read \"%s\"\n", buf); - - // @TODO: Better location for this code? - tell_the_server(DISTREN_REQUEST_PROGRESS); - fprintf(stderr, "Rendering...\n"); } execio_close(testrem); - /* end execio code */ if(ret == 1){ - fprintf(stderr,"Error starting Blender. Check your install.\n"); + fprintf(stderr,"Error starting Blender. Check your path and installation.\n"); } else{ - fprintf(stderr,"Execution was successful.\n"); + fprintf(stderr,"Execution of Blender was successful.\n"); } - // Consider placing the following in the exec_blender() function - } void xmlinit()