02 Jun, 2013, Skielin wrote in the 1st comment:
Votes: 0
Hey people was wondering if any of you would take a look at this code for me and maybe help me out

if (alias_free == NULL)

This code is what the system is saying is messed up but i'm not realizing anything wrong with it.
02 Jun, 2013, quixadhal wrote in the 2nd comment:
Votes: 0
Perhaps you could say how the "system" says it's "messed up"?
02 Jun, 2013, Rarva.Riendf wrote in the 3rd comment:
Votes: 0
>This code is what the system is saying is messed up but i'm not realizing anything wrong with it.

Nothing (if it compiles) , so the system is problably telling you something else.
02 Jun, 2013, Skielin wrote in the 4th comment:
Votes: 0
hey maybe this will help more tho thanks for the quick reply

save.c: In function save_char_obj_backup:
save.c:379: warning: format not a string literal and no format arguments
save.c: In function fread_opt_char:
save.c:5137: error: alias_free undeclared (first use in this function)
save.c:5137: error: (Each undeclared identifier is reported only once
save.c:5137: error: for each function it appears in.)
make: *** [save.o] Error 1
02 Jun, 2013, Rarva.Riendf wrote in the 5th comment:
Votes: 0
> error: alias_free undeclared (first use in this function)

Seems obvious enough, what don't you understand in that ?
02 Jun, 2013, Tyche wrote in the 6th comment:
Votes: 0
Skielin said:
hey maybe this will help more tho thanks for the quick reply
save.c: In function fread_opt_char:
save.c:5137: error: alias_free undeclared (first use in this function)
save.c:5137: error: (Each undeclared identifier is reported only once
save.c:5137: error: for each function it appears in.)
make: *** [save.o] Error 1


It can't find the declaration for the variable, alias_free.
A declaration looks like this:
int foo; // foo declared as an integer
struct bar * bar_ptr; // bar_ptr declared as a ptr to a bar structure

So you need to look for something like:
something * alias_free;

Maybe it's part of some structure, and
if (alias_free == NULL)
should be
if (ptrtosomestructure->alias_free == NULL)
02 Jun, 2013, Skielin wrote in the 7th comment:
Votes: 0
sadly i'm very rusty and don't know ALOT about coding so this is the error messages I am getting now not completely sure what I should be looking for
save.c: In function save_char_obj_backup:
save.c:379: error: expected ) before buf
save.c:379: warning: too few arguments for format
save.c: In function fread_opt_char:
save.c:5132: error: too few arguments to function fread_opt_char
save.c:5132: error: expected ; before in
save.c: In function do_finger:
save.c:7472: error: expected expression before : token
save.c:7472: warning: return with a value, in function returning void
make: *** [save.o] Error 1

Here is what those lines of code look like as well if maybe that will help

void
fread_opt_char (CHAR_DATA * ch, FILE * fp)
{
char buf[MSL];
char *word;
bool fMatch;

for (;;)
{
word = feof (fp) ? "End" : fread_word (fp);
fMatch = FALSE;

switch (UPPER (word[0]))
{
default:
case '*':
fMatch = TRUE;
fread_to_eol (fp);
break;

fread_char () in case 'A'
if (!str_cmp (word, "Alias"))
{
ALIAS_DATA *ali;

if (alias_free == NULL)
{
ali = alloc_perm (sizeof (*ali));
}
else
{
ali = alias_free;
alias_free = alias_free->next;
}
ali->short_n = fread_string (fp);
02 Jun, 2013, Tyche wrote in the 8th comment:
Votes: 0
When you get an error like this…
save.c: In function save_char_obj_backup:
save.c:379: error: expected ) before buf

Assuming line 379 is in this whereabouts…
void
fread_opt_char (CHAR_DATA * ch, FILE * fp)
{
char buf[MSL];

It means you've screwed up the something in file somewhere well before the error.
What you need to do is either find the missing parenthesis or semi-colon;
or restore the file to the original condition before you modified the code.

Edit: In other words, the whole file is suspect.
03 Jun, 2013, Skielin wrote in the 9th comment:
Votes: 0
Ok thanks alot I shall give it a try and see what I can turn up.
03 Jun, 2013, Skielin wrote in the 10th comment:
Votes: 0
Well thinking I might have to just give up on this code sadly it was broken before I got it, its the code base of a mud my blind buddy and i played some years ago so I been trying to put my very limited coding skills to work to fix it, if anyone would be willing to maybe help me out with some bug fixs let me know haha
0.0/10