Gitweb:     
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=10e6f32bdf02448f787d78647e75cf98a02f19a4
Commit:     10e6f32bdf02448f787d78647e75cf98a02f19a4
Parent:     fa7303e22c829a3364b5b7227aec9ed2d8623b2c
Author:     Randy Dunlap <[EMAIL PROTECTED]>
AuthorDate: Fri Feb 8 04:21:56 2008 -0800
Committer:  Linus Torvalds <[EMAIL PROTECTED]>
CommitDate: Fri Feb 8 09:22:41 2008 -0800

    getdelays: fix gcc warnings
    
    Fix gcc warnings in getdelays.c:
    
    Documentation/accounting/getdelays.c: In function 
'task_context_switch_counts':
    Documentation/accounting/getdelays.c:214: warning: format '%15lu' expects 
type 'long unsigned int', but argument 4 has type '__u64'
    Documentation/accounting/getdelays.c:214: warning: format '%15lu' expects 
type 'long unsigned int', but argument 5 has type '__u64'
    Documentation/accounting/getdelays.c: In function 'main':
    Documentation/accounting/getdelays.c:402: warning: format '%d' expects type 
'int', but argument 2 has type 'long unsigned int'
    Documentation/accounting/getdelays.c: In function 'get_family_id':
    Documentation/accounting/getdelays.c:171: warning: 'id' may be used 
uninitialized in this function
    
    One warning is not a problem and can be dismissed:
    Documentation/accounting/getdelays.c: In function 'main':
    Documentation/accounting/getdelays.c:236: warning: 'cmd_type' may be used 
uninitialized in this function
    
    Signed-off-by: Randy Dunlap <[EMAIL PROTECTED]>
    Acked-by: Balbir Singh <[EMAIL PROTECTED]>
    Signed-off-by: Andrew Morton <[EMAIL PROTECTED]>
    Signed-off-by: Linus Torvalds <[EMAIL PROTECTED]>
---
 Documentation/accounting/getdelays.c |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/Documentation/accounting/getdelays.c 
b/Documentation/accounting/getdelays.c
index d6cb1a8..40121b5 100644
--- a/Documentation/accounting/getdelays.c
+++ b/Documentation/accounting/getdelays.c
@@ -168,7 +168,7 @@ int get_family_id(int sd)
                char buf[256];
        } ans;
 
-       int id, rc;
+       int id = 0, rc;
        struct nlattr *na;
        int rep_len;
 
@@ -209,7 +209,7 @@ void print_delayacct(struct taskstats *t)
 void task_context_switch_counts(struct taskstats *t)
 {
        printf("\n\nTask   %15s%15s\n"
-              "       %15lu%15lu\n",
+              "       %15llu%15llu\n",
               "voluntary", "nonvoluntary",
               t->nvcsw, t->nivcsw);
 }
@@ -399,7 +399,7 @@ int main(int argc, char *argv[])
                        goto done;
                }
 
-               PRINTF("nlmsghdr size=%d, nlmsg_len=%d, rep_len=%d\n",
+               PRINTF("nlmsghdr size=%zu, nlmsg_len=%d, rep_len=%d\n",
                       sizeof(struct nlmsghdr), msg.n.nlmsg_len, rep_len);
 
 
-
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to