user_login_block doesn't display message
I successfully managed and fix it.
The code i was using to display the login block was as below
print drupal_render(drupal_get_form('user_login_block'));

This block used to generate the login block for the login functionality.
Now i tried to render the messages using theme_status_messages() function.
To fix the issue i created a function in my template.php file named THEMENAME_get_login_block().
In this function i added the theme_status_messages() function for the displaying the messages. So my function looked like given below.
function THEMENAME_get_login_block() {
    $form = drupal_render(drupal_get_form('user_login_block'));
    $messages = theme_status_messages();
    return $form.$messages;
}

And to render the block i used print THEMENAME_get_login_block();
This solved my problem. But still i am curious to know the root cause of such kind of events.
Any suggestions are welcomed....